mirror of
https://github.com/golang/go
synced 2024-11-26 04:07:59 -07:00
Don't cast nil to a fixed array type.
R=rsc DELTA=1 (0 added, 0 deleted, 1 changed) OCL=31916 CL=31937
This commit is contained in:
parent
c9399f13f8
commit
f0c00f7eee
@ -226,7 +226,7 @@ func TestAll(t *testing.T) { // TODO(r): wrap up better
|
|||||||
t.Errorf("FieldByName says absent field is present");
|
t.Errorf("FieldByName says absent field is present");
|
||||||
}
|
}
|
||||||
|
|
||||||
typ = Typeof(([32]int32)(nil));
|
typ = Typeof([32]int32{});
|
||||||
testType(t, 7, typ, "[32]int32");
|
testType(t, 7, typ, "[32]int32");
|
||||||
testType(t, 8, typ.(*ArrayType).Elem(), "int32");
|
testType(t, 8, typ.(*ArrayType).Elem(), "int32");
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user