Commit 4c9d84f0 authored by Rob Pike's avatar Rob Pike

Update fmt, refl, and rpc to exploit bug fixes in compiler

R=gri
OCL=14806
CL=14806
parent 6c72bfa5
......@@ -112,14 +112,14 @@ func (f *Fmt) pad(s string) {
if w > NByte {
w = NByte;
}
var buf[NByte] byte; // BUG: should be able to allocate variable size
buf := new([]byte, w);
for i := 0; i < w; i++ {
buf[i] = ' ';
}
if left {
s = string(buf)[0:w] + s;
s = string(buf) + s;
} else {
s = s + string(buf)[0:w];
s = s + string(buf);
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment