mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00: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
1 changed files with 1 additions and 1 deletions
|
|
@ -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…
Add table
Add a link
Reference in a new issue