]> Cypherpunks.ru repositories - gostls13.git/blobdiff - test/convert2.go
cmd/compile/internal/inline: score call sites exposed by inlines
[gostls13.git] / test / convert2.go
index e7044b24530eb70dc7e2045e1da11910a7bf72eb..ef93fe1f9bda37941071aa3c8c1217d2a367a150 100644 (file)
@@ -313,3 +313,17 @@ func _() {
        t = u       // ERROR "cannot use .* in assignment|incompatible type"
        t = (*T)(u) // ERROR "cannot convert"
 }
+
+func _() {
+       var s []byte
+       _ = ([4]byte)(s)
+       _ = (*[4]byte)(s)
+
+       type A [4]byte
+       _ = (A)(s)
+       _ = (*A)(s)
+
+       type P *[4]byte
+       _ = (P)(s)
+       _ = (*P)(s) // ERROR "cannot convert"
+}