fix up some irregular indentation
R=rsc
OCL=33382
CL=33391
diff --git a/test/fixedbugs/bug024.go b/test/fixedbugs/bug024.go
index 51bf529..0f4b2ca 100644
--- a/test/fixedbugs/bug024.go
+++ b/test/fixedbugs/bug024.go
@@ -7,11 +7,11 @@
package main
func main() {
- var i int;
- i = '\'';
- i = '\\';
- var s string;
- s = "\"";
+ var i int;
+ i = '\'';
+ i = '\\';
+ var s string;
+ s = "\"";
}
/*
bug.go:5: unknown escape sequence: '
diff --git a/test/fixedbugs/bug030.go b/test/fixedbugs/bug030.go
index 4ee65d0..e1fce01 100644
--- a/test/fixedbugs/bug030.go
+++ b/test/fixedbugs/bug030.go
@@ -7,6 +7,6 @@
package main
func main() {
- var x int;
- x := 0; // ERROR "declar|:="
+ var x int;
+ x := 0; // ERROR "declar|:="
}
diff --git a/test/fixedbugs/bug039.go b/test/fixedbugs/bug039.go
index 591b7fe..30fbdbd 100644
--- a/test/fixedbugs/bug039.go
+++ b/test/fixedbugs/bug039.go
@@ -7,5 +7,5 @@
package main
func main (x int) { // GCCGO_ERROR "previous"
- var x int; // ERROR "redecl|redefinition"
+ var x int; // ERROR "redecl|redefinition"
}
diff --git a/test/fixedbugs/bug051.go b/test/fixedbugs/bug051.go
index 199a4b9..dd16623 100644
--- a/test/fixedbugs/bug051.go
+++ b/test/fixedbugs/bug051.go
@@ -7,9 +7,9 @@
package main
func f() int {
- return 0;
+ return 0;
}
func main() {
- const n = f(); // ERROR "const"
+ const n = f(); // ERROR "const"
}
diff --git a/test/fixedbugs/bug052.go b/test/fixedbugs/bug052.go
index 07c651d..d2c1b50 100644
--- a/test/fixedbugs/bug052.go
+++ b/test/fixedbugs/bug052.go
@@ -7,14 +7,14 @@
package main
func main() {
- c := 10;
- d := 7;
- var x [10]int;
- i := 0;
- /* this works:
- q := c/d;
- x[i] = q;
- */
- // this doesn't:
- x[i] = c/d; // BUG segmentation fault
+ c := 10;
+ d := 7;
+ var x [10]int;
+ i := 0;
+ /* this works:
+ q := c/d;
+ x[i] = q;
+ */
+ // this doesn't:
+ x[i] = c/d; // BUG segmentation fault
}
diff --git a/test/fixedbugs/bug053.go b/test/fixedbugs/bug053.go
index fe6ca49..602b0a1 100644
--- a/test/fixedbugs/bug053.go
+++ b/test/fixedbugs/bug053.go
@@ -7,5 +7,5 @@
package main
func main() {
- var len int; // len should not be a keyword - this doesn't compile
+ var len int; // len should not be a keyword - this doesn't compile
}
diff --git a/test/fixedbugs/bug057.go b/test/fixedbugs/bug057.go
index 1c959b8..3847dff 100644
--- a/test/fixedbugs/bug057.go
+++ b/test/fixedbugs/bug057.go
@@ -7,15 +7,15 @@
package main
type T struct {
- s string;
+ s string;
}
func main() {
- s := "";
- l1 := len(s);
- var t T;
- l2 := len(t.s); // BUG: cannot take len() of a string field
+ s := "";
+ l1 := len(s);
+ var t T;
+ l2 := len(t.s); // BUG: cannot take len() of a string field
}
/*
diff --git a/test/fixedbugs/bug058.go b/test/fixedbugs/bug058.go
index da47ae5..e2b4a24 100644
--- a/test/fixedbugs/bug058.go
+++ b/test/fixedbugs/bug058.go
@@ -10,10 +10,10 @@
var m map[string] *Box;
func main() {
- m := make(map[string] *Box);
- s := "foo";
- var x *Box = nil;
- m[s] = x;
+ m := make(map[string] *Box);
+ s := "foo";
+ var x *Box = nil;
+ m[s] = x;
}
/*
diff --git a/test/fixedbugs/bug062.go b/test/fixedbugs/bug062.go
index c869eb2..8ee5c84 100644
--- a/test/fixedbugs/bug062.go
+++ b/test/fixedbugs/bug062.go
@@ -7,5 +7,5 @@
package main
func main() {
- var s string = nil; // ERROR "illegal|invalid|incompatible|cannot"
+ var s string = nil; // ERROR "illegal|invalid|incompatible|cannot"
}
diff --git a/test/fixedbugs/bug097.go b/test/fixedbugs/bug097.go
index 70bd6e2..d5e4099 100644
--- a/test/fixedbugs/bug097.go
+++ b/test/fixedbugs/bug097.go
@@ -41,7 +41,7 @@
*/
/* An array composite literal needs to be created freshly every time.
- It is a "construction" of an array after all. If I pass the address
- of the array to some function, it may store it globally. Same applies
- to struct literals.
+ It is a "construction" of an array after all. If I pass the address
+ of the array to some function, it may store it globally. Same applies
+ to struct literals.
*/
diff --git a/test/fixedbugs/bug106.dir/bug0.go b/test/fixedbugs/bug106.dir/bug0.go
index 7daf209..d9c26a00 100644
--- a/test/fixedbugs/bug106.dir/bug0.go
+++ b/test/fixedbugs/bug106.dir/bug0.go
@@ -3,4 +3,5 @@
// license that can be found in the LICENSE file.
package bug0
+
const A = -1
diff --git a/test/fixedbugs/bug106.dir/bug1.go b/test/fixedbugs/bug106.dir/bug1.go
index 6ef40e9..87f4fbb 100644
--- a/test/fixedbugs/bug106.dir/bug1.go
+++ b/test/fixedbugs/bug106.dir/bug1.go
@@ -3,5 +3,6 @@
// license that can be found in the LICENSE file.
package bug1
+
import "./bug0"
diff --git a/test/fixedbugs/bug107.go b/test/fixedbugs/bug107.go
index 80fa966..87cdca7 100644
--- a/test/fixedbugs/bug107.go
+++ b/test/fixedbugs/bug107.go
@@ -7,8 +7,8 @@
package main
import os "os"
func f() (os int) {
- // In the next line "os" should refer to the result variable, not
- // to the package.
- v := os.Open("", 0, 0); // ERROR "undefined"
- return 0
+ // In the next line "os" should refer to the result variable, not
+ // to the package.
+ v := os.Open("", 0, 0); // ERROR "undefined"
+ return 0
}
diff --git a/test/fixedbugs/bug109.go b/test/fixedbugs/bug109.go
index 61ede1b..c679771 100644
--- a/test/fixedbugs/bug109.go
+++ b/test/fixedbugs/bug109.go
@@ -14,11 +14,11 @@
/*
6g bugs/bug109.go
bugs/bug109.go:5: illegal types for operand: MUL
- (<float64>FLOAT64)
- (<float32>FLOAT32)
+ (<float64>FLOAT64)
+ (<float32>FLOAT32)
bugs/bug109.go:5: illegal types for operand: AS
- (<float64>FLOAT64)
+ (<float64>FLOAT64)
bugs/bug109.go:6: illegal types for operand: RETURN
- (<float32>FLOAT32)
- (<float64>FLOAT64)
+ (<float32>FLOAT32)
+ (<float64>FLOAT64)
*/
diff --git a/test/fixedbugs/bug113.go b/test/fixedbugs/bug113.go
index 14bd076..4b9b139 100644
--- a/test/fixedbugs/bug113.go
+++ b/test/fixedbugs/bug113.go
@@ -9,12 +9,12 @@
func foo1(i int) int { return i }
func foo2(i int32) int32 { return i }
func main() {
- var i I;
- i = 1;
- var v1 = i.(int);
- if foo1(v1) != 1 { panicln(1) }
- var v2 = int32(i.(int));
- if foo2(v2) != 1 { panicln(2) }
- var v3 = i.(int32); // This type conversion should fail at runtime.
- if foo2(v3) != 1 { panicln(3) }
+ var i I;
+ i = 1;
+ var v1 = i.(int);
+ if foo1(v1) != 1 { panicln(1) }
+ var v2 = int32(i.(int));
+ if foo2(v2) != 1 { panicln(2) }
+ var v3 = i.(int32); // This type conversion should fail at runtime.
+ if foo2(v3) != 1 { panicln(3) }
}
diff --git a/test/fixedbugs/bug117.go b/test/fixedbugs/bug117.go
index 8e447cd..2cb6d6c 100644
--- a/test/fixedbugs/bug117.go
+++ b/test/fixedbugs/bug117.go
@@ -8,18 +8,18 @@
type S struct { a int }
type PS *S
func (p *S) get() int {
- return p.a
+ return p.a
}
func fn(p PS) int {
- // p has type PS, and PS has no methods.
- // (a compiler might see that p is a pointer
- // and go looking in S without noticing PS.)
- return p.get() // ERROR "undefined"
+ // p has type PS, and PS has no methods.
+ // (a compiler might see that p is a pointer
+ // and go looking in S without noticing PS.)
+ return p.get() // ERROR "undefined"
}
func main() {
- s := S{1};
- if s.get() != 1 {
- panic()
- }
+ s := S{1};
+ if s.get() != 1 {
+ panic()
+ }
}
diff --git a/test/fixedbugs/bug118.go b/test/fixedbugs/bug118.go
index 94f5ffd..1271f5b 100644
--- a/test/fixedbugs/bug118.go
+++ b/test/fixedbugs/bug118.go
@@ -7,9 +7,9 @@
package main
func Send(c chan int) int {
- select {
- default:
- return 1;
- }
- return 2;
+ select {
+ default:
+ return 1;
+ }
+ return 2;
}
diff --git a/test/fixedbugs/bug123.go b/test/fixedbugs/bug123.go
index f26a046..bdac674 100644
--- a/test/fixedbugs/bug123.go
+++ b/test/fixedbugs/bug123.go
@@ -7,8 +7,8 @@
package main
const ( F = 1 )
func fn(i int) int {
- if i == F() { // ERROR "func"
- return 0
- }
- return 1
+ if i == F() { // ERROR "func"
+ return 0
+ }
+ return 1
}
diff --git a/test/fixedbugs/bug127.go b/test/fixedbugs/bug127.go
index ca7b134..25b4811 100644
--- a/test/fixedbugs/bug127.go
+++ b/test/fixedbugs/bug127.go
@@ -6,7 +6,7 @@
package main
func main() {
- var x int64 = 0;
- println(x != nil); // ERROR "illegal|incompatible|nil"
- println(0 != nil); // ERROR "illegal|incompatible|nil"
+ var x int64 = 0;
+ println(x != nil); // ERROR "illegal|incompatible|nil"
+ println(0 != nil); // ERROR "illegal|incompatible|nil"
}
diff --git a/test/fixedbugs/bug130.go b/test/fixedbugs/bug130.go
index 3d13cb8..855c707 100644
--- a/test/fixedbugs/bug130.go
+++ b/test/fixedbugs/bug130.go
@@ -14,9 +14,9 @@
func (p *S) send(c chan <- int) { c <- p.v }
func main() {
- s := S{0};
- var i I = &s;
- c := make(chan int);
- go i.send(c);
- os.Exit(<-c);
+ s := S{0};
+ var i I = &s;
+ c := make(chan int);
+ go i.send(c);
+ os.Exit(<-c);
}
diff --git a/test/fixedbugs/bug131.go b/test/fixedbugs/bug131.go
index 8205aa5..e5d4ca0 100644
--- a/test/fixedbugs/bug131.go
+++ b/test/fixedbugs/bug131.go
@@ -7,6 +7,6 @@
package main
func main() {
- const a uint64 = 10;
- var b int64 = a; // ERROR "convert|cannot|incompatible"
+ const a uint64 = 10;
+ var b int64 = a; // ERROR "convert|cannot|incompatible"
}
diff --git a/test/fixedbugs/bug135.go b/test/fixedbugs/bug135.go
index d7115c4..252aa87 100644
--- a/test/fixedbugs/bug135.go
+++ b/test/fixedbugs/bug135.go
@@ -12,7 +12,7 @@
func (t *T) foo() {}
func main() {
- t := new(T);
- var i interface {};
- f, ok := i.(Foo);
+ t := new(T);
+ var i interface {};
+ f, ok := i.(Foo);
}