summaryrefslogtreecommitdiff
path: root/src/lib/json/struct_test.go
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2008-12-19 03:05:37 -0800
committerRuss Cox <rsc@golang.org>2008-12-19 03:05:37 -0800
commit65e4c6bf1819903c1b751a3b305a6d2ec07cc283 (patch)
tree183e8cd345f5f895d2cbc36dd8f8be93640303c3 /src/lib/json/struct_test.go
parent89995dcecf37b9a21c26783dcf8ab506da237363 (diff)
downloadgolang-65e4c6bf1819903c1b751a3b305a6d2ec07cc283.tar.gz
change *map to map; *chan to chan; new(T) to new(*T)
fix bugs left over from *[] to [] conversion. TBR=r OCL=21576 CL=21581
Diffstat (limited to 'src/lib/json/struct_test.go')
-rw-r--r--src/lib/json/struct_test.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/json/struct_test.go b/src/lib/json/struct_test.go
index 85dbd8881..9f8615a36 100644
--- a/src/lib/json/struct_test.go
+++ b/src/lib/json/struct_test.go
@@ -26,7 +26,7 @@ type MyStruct struct {
fl float;
fl32 float32;
fl64 float64;
- a []string;
+ a *[]string; // TODO(rsc): Should be able to use []string.
my *MyStruct;
};
@@ -69,7 +69,7 @@ export func TestUnmarshal(t *testing.T) {
Check(t, m.fl==11.5, "fl", m.fl);
Check(t, m.fl32==12.25, "fl32", m.fl32);
Check(t, m.fl64==13.75, "fl64", m.fl64);
-// Check(t, m.a!=nil, "a", m.a); // TODO(rsc): uncomment once []string as interface works
+ Check(t, m.a!=nil, "a", m.a);
if m.a != nil {
Check(t, m.a[0]=="x", "a[0]", m.a[0]);
Check(t, m.a[1]=="y", "a[1]", m.a[1]);