From 6f4b08267661cd25a11df61c0454533342aaf709 Mon Sep 17 00:00:00 2001 From: Pavel Merzlyakov Date: Thu, 7 Sep 2023 11:35:20 +0300 Subject: [PATCH] remove json tag's string modifier --- tpl/macros_struct.twig | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tpl/macros_struct.twig b/tpl/macros_struct.twig index 190a5b1..2c1bf76 100644 --- a/tpl/macros_struct.twig +++ b/tpl/macros_struct.twig @@ -43,7 +43,7 @@ type {{ s.name }} struct { {%~ for f in pkey %} - {{ f|fname }} {{ f.type|go_type }} `json:"{{ f|alias }},string" msgpack:"{{ f|alias }}"` + {{ f|fname }} {{ f.type|go_type }} `json:"{{ f|alias }}" msgpack:"{{ f|alias }}"` {%~ endfor %} {{ json_fields_type }} @@ -51,7 +51,7 @@ type {{ s.name }} struct { type {{ json_fields_type }} struct{ {%~ for f in json_fields %} - {{ f|fname }} {{ f.type|go_type }} `json:"{{ f|alias }},string" msgpack:"{{ f|alias }}"` + {{ f|fname }} {{ f.type|go_type }} `json:"{{ f|alias }}" msgpack:"{{ f|alias }}"` {%~ endfor %} changedFields meta.ChangedFields @@ -882,7 +882,7 @@ type {{ s.name }} struct { {% endif %} {% for f in s.fields %} - {{ f|fname }} {{ f.type|go_type(f.tokens) }} `json:"{{ f|alias }},string" msgpack:"{{ f|alias }}"` + {{ f|fname }} {{ f.type|go_type(f.tokens) }} `json:"{{ f|alias }}" msgpack:"{{ f|alias }}"` {% endfor %} {% if has_token(s, 'bitfields') %}