mirror of
https://github.com/golang/go
synced 2024-11-22 03:34:40 -07:00
- fixed old test cases with wrong syntax
- added more test cases to Makefile - fixed another parser issue (possibly a 6g bug - to be tracked down) R=r OCL=15516 CL=15516
This commit is contained in:
parent
a1ee6804dd
commit
2b70c6add3
@ -14,11 +14,10 @@ export type Node struct {
|
||||
left, right *Node;
|
||||
val bool;
|
||||
f Foo;
|
||||
const, type, var, package int;
|
||||
}
|
||||
|
||||
export func (p *Node) case(x int) {};
|
||||
export func (p *Node) F(x int) {};
|
||||
|
||||
export type I interface {
|
||||
func();
|
||||
f();
|
||||
}
|
||||
|
@ -46,15 +46,6 @@ type F5 (a, b int, c float) (z T5, ok bool)
|
||||
type F6 (a int, b float) bool
|
||||
type F7 (a int, b float, c, d *bool) bool
|
||||
|
||||
export type M0 (p T5) . ();
|
||||
type (
|
||||
M1 (p T5) . (a int);
|
||||
M2 (p T5) . (a, b int, c float);
|
||||
M3 (p T5) . () bool;
|
||||
M4 (p T5) . (a int) (z T5, ok bool);
|
||||
)
|
||||
export type M5 (p T5) . (a, b int, c float) (z T5, ok bool);
|
||||
|
||||
type T6 chan int
|
||||
type T7 <- chan *T6
|
||||
type T8 chan <- *T6
|
||||
|
@ -10,8 +10,10 @@ pretty: pretty.6
|
||||
|
||||
test: pretty
|
||||
pretty *.go
|
||||
pretty $(GOROOT)/test/fixedbugs/*.go # some files legally don't compile
|
||||
pretty ../gosrc/*.go
|
||||
pretty $(GOROOT)/test/sieve.go
|
||||
pretty $(GOROOT)/test/bugs/*.go # some files legally don't compile
|
||||
pretty $(GOROOT)/test/fixedbugs/*.go # some files legally don't compile
|
||||
pretty $(GOROOT)/src/pkg/*.go
|
||||
pretty $(GOROOT)/src/lib/flag.go
|
||||
pretty $(GOROOT)/src/lib/fmt.go
|
||||
@ -19,7 +21,7 @@ test: pretty
|
||||
pretty $(GOROOT)/src/lib/math/*.go
|
||||
pretty $(GOROOT)/src/lib/container/*.go
|
||||
pretty $(GOROOT)/src/syscall/*.go
|
||||
echo "PASSED"
|
||||
echo "DONE"
|
||||
|
||||
install: pretty
|
||||
cp pretty $(HOME)/bin/pretty
|
||||
|
@ -453,7 +453,7 @@ func (P *Parser) TryType() bool {
|
||||
case Scanner.LBRACK: P.ParseArrayType();
|
||||
case Scanner.CHAN, Scanner.ARROW: P.ParseChannelType();
|
||||
case Scanner.INTERFACE: P.ParseInterfaceType();
|
||||
case Scanner.LPAREN: P.ParseFunctionType();
|
||||
case Scanner.LPAREN: P.ParseSignature();
|
||||
case Scanner.MAP: P.ParseMapType();
|
||||
case Scanner.STRUCT: P.ParseStructType();
|
||||
case Scanner.MUL: P.ParsePointerType();
|
||||
|
Loading…
Reference in New Issue
Block a user