aboutsummaryrefslogtreecommitdiff
path: root/test/switch.go
AgeCommit message (Collapse)Author
2013-03-15cmd/gc: disallow fallthrough in final case of switchTyler Bunnell
Small change to cmd/gc to catch a "fallthrough" in the final case of a switch. R=golang-dev, rsc, mtj CC=golang-dev https://golang.org/cl/7841043
2013-02-26cmd/gc: accept cases with same value but different types in switch.Rémy Oudompheng
Fixes #4781. R=golang-dev, rsc CC=golang-dev https://golang.org/cl/7365056
2013-02-11test: a number of fixes.Alan Donovan
Details: - reorder.go: delete p8. (Once expectation is changed per b/4627 it is identical to p1.) - switch.go: added some more (degenerate) switches. - range.go: improved error messages in a few cases. - method.go: added tests of calls to promoted methods. R=iant CC=golang-dev https://golang.org/cl/7306087
2012-09-17cmd/gc: add missing conversion from bool to interface in switches.Daniel Morsing
In switches without an expression, the compiler would not convert the implicit true to an interface, causing codegen errors. Fixes #3980. R=golang-dev, rsc CC=golang-dev https://golang.org/cl/6497147
2012-08-03cmd/gc: accept switches on comparable arrays.Rémy Oudompheng
The compiler is incorrectly rejecting switches on arrays of comparable types. It also doesn't catch incomparable structs when typechecking the switch, leading to unreadable errors during typechecking of the generated code. Fixes #3894. R=rsc CC=gobot, golang-dev, r, remy https://golang.org/cl/6442074
2012-02-24test/[n-z]*.go: add documentationRob Pike
R=golang-dev, bradfitz, r CC=golang-dev https://golang.org/cl/5700056
2012-02-16test: use testlib (final 61)Russ Cox
X ,s;^// \$G (\$D/)?\$F\.go *$;// compile;g X ,s;^// \$G (\$D/)?\$F\.go && \$L \$F\.\$A *$;// build;g X ,s;^// \$G (\$D/)?\$F\.go && \$L \$F\.\$A && \./\$A\.out *$;// run;g X ,s;^// errchk \$G( -e)? (\$D/)?\$F\.go *$;// errorcheck;g R=golang-dev, bradfitz CC=golang-dev https://golang.org/cl/5671080
2011-11-13gc: remove func, map compareRuss Cox
R=ken, ken CC=golang-dev https://golang.org/cl/5373079
2010-09-04test: remove semiocolons.Rob Pike
The ken directory is untouched so we have some examples with explicit semis. R=gri CC=golang-dev https://golang.org/cl/2157041
2009-09-14fix "declared and not used" in tests;Russ Cox
also template/template.go, missed last time. R=r DELTA=116 (61 added, 10 deleted, 45 changed) OCL=34620 CL=34622
2008-08-11fix bug depot:Rob Pike
1) fix print statements, panic statements (parentheses required) 2) len is now allowed as a var name (bug053) R=gri OCL=14106 CL=14106
2008-07-08test update. also remove two duplicatesRob Pike
SVN=126336
2008-06-15now checks for lvalue/rvalue context ofKen Thompson
expressions. start of generics for calling builtin functions start of map type 'any' demoted from reserved word to type SVN=122808
2008-06-06- fixed a few tests and added 3 incorrectly succeeding testsRobert Griesemer
- updated go_lang.txt to be more uniform and match the implementation - made makehtml work on Mac - fixed a couple of bugs in go.atg SVN=121520
2008-06-06lots of new testsRob Pike
SVN=121464