Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(1755)

Delta Between Two Patch Sets: test/ddd1.go

Issue 5316043: code review 5316043: gc: clean up printing. (Closed)
Left Patch Set: diff -r 5a6c90d25d31 https://go.googlecode.com/hg/ Created 13 years, 5 months ago
Right Patch Set: diff -r 01516e31b4f0 https://go.googlecode.com/hg/ Created 13 years, 5 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
Right: Side by side diff | Download
« no previous file with change/comment | « src/pkg/reflect/all_test.go ('k') | test/fixedbugs/bug340.go » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
(no file at all)
1 // errchk $G -e $D/$F.go 1 // errchk $G -e $D/$F.go
2 2
3 // Copyright 2010 The Go Authors. All rights reserved. 3 // Copyright 2010 The Go Authors. All rights reserved.
4 // Use of this source code is governed by a BSD-style 4 // Use of this source code is governed by a BSD-style
5 // license that can be found in the LICENSE file. 5 // license that can be found in the LICENSE file.
6 6
7 package main 7 package main
8 8
9 import "unsafe" 9 import "unsafe"
10 10
11 func sum(args ...int) int { return 0 } 11 func sum(args ...int) int { return 0 }
12 12
13 var ( 13 var (
14 _ = sum(1, 2, 3) 14 _ = sum(1, 2, 3)
15 _ = sum() 15 _ = sum()
16 _ = sum(1.0, 2.0) 16 _ = sum(1.0, 2.0)
17 _ = sum(1.5) // ERROR "integer" 17 _ = sum(1.5) // ERROR "integer"
18 » _ = sum("hello") // ERROR ".hello. .type string. as type int|incompatib le" 18 » _ = sum("hello") // ERROR ".hello. .type ideal string. as type int|inco mpatible"
19 _ = sum([]int{1}) // ERROR "\[\]int literal.*as type int|incompatible" 19 _ = sum([]int{1}) // ERROR "\[\]int literal.*as type int|incompatible"
20 ) 20 )
21 21
22 type T []T 22 type T []T
23 23
24 func funny(args ...T) int { return 0 } 24 func funny(args ...T) int { return 0 }
25 25
26 var ( 26 var (
27 _ = funny(nil) 27 _ = funny(nil)
28 _ = funny(nil, nil) 28 _ = funny(nil, nil)
(...skipping 11 matching lines...) Expand all
40 _ = make([]byte, n...) // ERROR "[.][.][.]" 40 _ = make([]byte, n...) // ERROR "[.][.][.]"
41 // TODO(rsc): enable after gofmt bug is fixed 41 // TODO(rsc): enable after gofmt bug is fixed
42 // _ = make([]byte, 10 ...) // error "[.][.][.]" 42 // _ = make([]byte, 10 ...) // error "[.][.][.]"
43 var x int 43 var x int
44 _ = unsafe.Pointer(&x...) // ERROR "[.][.][.]" 44 _ = unsafe.Pointer(&x...) // ERROR "[.][.][.]"
45 _ = unsafe.Sizeof(x...) // ERROR "[.][.][.]" 45 _ = unsafe.Sizeof(x...) // ERROR "[.][.][.]"
46 _ = [...]byte("foo") // ERROR "[.][.][.]" 46 _ = [...]byte("foo") // ERROR "[.][.][.]"
47 _ = [...][...]int{{1,2,3},{4,5,6}} // ERROR "[.][.][.]" 47 _ = [...][...]int{{1,2,3},{4,5,6}} // ERROR "[.][.][.]"
48 } 48 }
49 49
LEFTRIGHT

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b