summaryrefslogtreecommitdiff
path: root/decode_scan_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'decode_scan_test.go')
-rw-r--r--decode_scan_test.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/decode_scan_test.go b/decode_scan_test.go
index 5d1542f..f5ceee0 100644
--- a/decode_scan_test.go
+++ b/decode_scan_test.go
@@ -346,7 +346,8 @@ func TestElemRuneTypeScanner2(t *testing.T) {
{'"', 1, internal.RuneTypeStringEnd, nil},
{':', 1, internal.RuneTypeObjectColon, nil},
}
- var expStr, actStr []string
+ expStr := make([]string, 0, len(exp))
+ actStr := make([]string, 0, len(exp))
for _, iExp := range exp {
var iAct ReadRuneTypeResult
iAct.r, iAct.s, iAct.t, iAct.e = parent.ReadRuneType()