Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go
Commits
9a58c9c5
Commit
9a58c9c5
authored
Jun 16, 2008
by
Rob Pike
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update more tests to reflect tweaked grammar for if, switch
SVN=122916
parent
daebf91d
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
9 additions
and
29 deletions
+9
-29
test/bugs/bug006.go
test/bugs/bug006.go
+0
-14
test/fixedbugs/bug001.go
test/fixedbugs/bug001.go
+0
-0
test/fixedbugs/bug002.go
test/fixedbugs/bug002.go
+0
-0
test/fixedbugs/bug003.go
test/fixedbugs/bug003.go
+1
-2
test/fixedbugs/bug004.go
test/fixedbugs/bug004.go
+0
-0
test/golden.out
test/golden.out
+8
-13
No files found.
test/bugs/bug006.go
View file @
9a58c9c5
...
...
@@ -16,17 +16,3 @@ func main() int {
if
g
!=
4.5
{
print
" fail
\n
"
;
return
1
;
}
return
0
;
}
/*
should 4.5 * iota be ok? perhaps, perhaps not. but (all!) error msgs are bad:
bug6.go:4: illegal combination of literals 0 0
bug6.go:4: expression must be a constant
bug6.go:4: expression must be a constant
bug6.go:4: expression must be a constant
bug6.go:4: expression must be a constant
bug6.go:4: expression must be a constant
bug6.go:4: expression must be a constant
bug6.go:4: expression must be a constant
bug6.go:4: expression must be a constant
bug6.go:4: expression must be a constant
bug6.go:4: fatal error: too many errors
*/
test/bugs/bug001.go
→
test/
fixed
bugs/bug001.go
View file @
9a58c9c5
File moved
test/bugs/bug002.go
→
test/
fixed
bugs/bug002.go
View file @
9a58c9c5
File moved
test/bugs/bug003.go
→
test/
fixed
bugs/bug003.go
View file @
9a58c9c5
...
...
@@ -7,9 +7,8 @@
package
main
func
main
()
{
switch
;
{
}
// compiles; should be an error (should be simplevardecl before ;)
switch
;
{
case
true
:
return
;
default
:
return
}
}
/*
bug003.go:6: switch statement must have case labels
bug003.go:6: fatal error: walkswitch: not case EMPTY
*/
test/bugs/bug004.go
→
test/
fixed
bugs/bug004.go
View file @
9a58c9c5
File moved
test/golden.out
View file @
9a58c9c5
...
...
@@ -114,19 +114,6 @@ abcxyz-abcxyz-abcxyz-abcxyz-abcxyz-abcxyz-abcxyz
=========== ken/strvar.go
=========== bugs/bug001.go
BUG: known to succeed incorrectly
=========== bugs/bug002.go
BUG: known to succeed incorrectly
=========== bugs/bug003.go
bugs/bug003.go:6: switch statement must have case labels
BUG: fatal error
=========== bugs/bug004.go
BUG: known to succeed incorrectly
=========== bugs/bug006.go
zero
fail
...
...
@@ -240,6 +227,14 @@ BUG: known to fail incorrectly
=========== fixedbugs/bug000.go
=========== fixedbugs/bug001.go
=========== fixedbugs/bug002.go
=========== fixedbugs/bug003.go
=========== fixedbugs/bug004.go
=========== fixedbugs/bug005.go
=========== fixedbugs/bug007.go
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment