• Russ Cox's avatar
    new interface error messages · 6f07ec72
    Russ Cox authored
    	package main
    	func main() {
    		var i interface { } = 1;
    		a := i.(*[]byte);
    	}
    
    interface { } is int, not *[]uint8
    throw: interface conversion
    
    	package main
    	func main() {
    		var i interface { };
    		a := i.(*[]byte);
    	}
    
    interface is nil, not *[]uint8
    throw: interface conversion
    
    	package main
    	func main() {
    		i := sys.unreflect(0, "*bogus");
    		a := i.(*[]byte);
    	}
    
    interface { } is *bogus, not *[]uint8
    throw: interface conversion
    
    R=r
    DELTA=30  (24 added, 2 deleted, 4 changed)
    OCL=18548
    CL=18565
    6f07ec72
iface.c 8.76 KB