aboutsummaryrefslogtreecommitdiff
path: root/test/interface
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2010-09-08 21:03:24 -0700
committerIan Lance Taylor <iant@golang.org>2010-09-08 21:03:24 -0700
commit2d8433a720f79cf758c85046b45fd183ff63e788 (patch)
tree2301dc2b9d525abc5d02041ba040a48dbe8022d6 /test/interface
parentf4a5d733a589378e2a7ffa0ab2ba4175a7510cd2 (diff)
downloadgo-2d8433a720f79cf758c85046b45fd183ff63e788.tar.gz
go-2d8433a720f79cf758c85046b45fd183ff63e788.zip
test: Match gccgo error messages.
explicit.go:36:4: error: incompatible types in assignment (need explicit conversion) explicit.go:41:4: error: incompatible types in assignment (type has no methods) explicit.go:42:4: error: incompatible types in assignment (need explicit conversion) explicit.go:45:5: error: incompatible types in assignment (need explicit conversion; missing method ‘N’) explicit.go:48:9: error: invalid type conversion (need explicit conversion; missing method ‘N’) explicit.go:51:4: error: incompatible types in assignment explicit.go:51:7: error: invalid type conversion (need explicit conversion) explicit.go:57:10: error: impossible type assertion: type does not implement interface (type has no methods) explicit.go:62:10: error: impossible type assertion: type does not implement interface (incompatible type for method ‘M’ (different number of parameters)) explicit.go:67:5: error: incompatible type in initialization (type has no methods) explicit.go:68:5: error: incompatible type in initialization (incompatible type for method ‘M’ (different number of parameters)) explicit.go:70:11: error: invalid type conversion (type has no methods) explicit.go:71:11: error: invalid type conversion (incompatible type for method ‘M’ (different number of parameters)) R=rsc CC=golang-dev https://golang.org/cl/2139044
Diffstat (limited to 'test/interface')
-rw-r--r--test/interface/explicit.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/interface/explicit.go b/test/interface/explicit.go
index 120135cb68..b952f8fc8a 100644
--- a/test/interface/explicit.go
+++ b/test/interface/explicit.go
@@ -42,10 +42,10 @@ func main() {
t = i // ERROR "incompatible|need type assertion"
i = i2 // ok
- i2 = i // ERROR "missing N method"
+ i2 = i // ERROR "incompatible|missing N method"
i = I(i2) // ok
- i2 = I2(i) // ERROR "missing N method"
+ i2 = I2(i) // ERROR "invalid|missing N method"
e = E(t) // ok
t = T(e) // ERROR "need explicit|need type assertion|incompatible"
@@ -64,8 +64,8 @@ var _ = m.(Int) // ERROR "impossible type assertion"
var ii int
var jj Int
-var m1 M = ii // ERROR "missing"
-var m2 M = jj // ERROR "wrong type for M method"
+var m1 M = ii // ERROR "incompatible|missing"
+var m2 M = jj // ERROR "incompatible|wrong type for M method"
-var m3 = M(ii) // ERROR "missing"
-var m4 = M(jj) // ERROR "wrong type for M method"
+var m3 = M(ii) // ERROR "invalid|missing"
+var m4 = M(jj) // ERROR "invalid|wrong type for M method"