reflect: add sipmlified strconv.Quote() implementation for struct tags

This commit is contained in:
Damian Gryski
2023-03-24 13:48:00 -07:00
committed by Ron Evans
parent 195de23d3b
commit 5faff2e13a
3 changed files with 101 additions and 6 deletions
+1 -1
View File
@@ -188,7 +188,6 @@ var typeTests = []pair{
}{},
"struct { a int8; b int8; c int8; d int8; e int8; f int32 }",
},
/* // TODO(tinygo): Reflects tags aren't properly quoted
{struct {
x struct {
a int8 `reflect:"hi there"`
@@ -203,6 +202,7 @@ var typeTests = []pair{
}{},
`struct { a int8 "reflect:\"hi \\x00there\\t\\n\\\"\\\\\"" }`,
},
/* // TODO(tinygo): Functions not supported
{struct {
x struct {
f func(args ...int)