diff options
author | Přemysl Eric Janouch <p@janouch.name> | 2024-11-07 08:57:28 +0100 |
---|---|---|
committer | Přemysl Eric Janouch <p@janouch.name> | 2024-11-07 11:01:41 +0100 |
commit | aacf1b1d47824de2c924874e3d6cdad1d8b5ba2b (patch) | |
tree | e76dade58f3853ec96a751b3c45ca22a23274503 /liberty-xui.c | |
parent | 49d7cb12bb2f47216528ea6d6f58869e0cf12a2e (diff) | |
download | liberty-aacf1b1d47824de2c924874e3d6cdad1d8b5ba2b.tar.gz liberty-aacf1b1d47824de2c924874e3d6cdad1d8b5ba2b.tar.xz liberty-aacf1b1d47824de2c924874e3d6cdad1d8b5ba2b.zip |
lxdrgen-go: improve usability
Turning union tags into read-only methods of actual types:
- eliminates duplicated JSON unmarshalling of tags,
- makes AppendTo/ConsumeFrom symmetrical in nature,
- eliminates duplicated AppendTo code,
- eliminates trivial AppendTo methods for subtypes without fields,
- gives us an opportunity to use a more specific interface than "any"
(the type being anonymous is an acknowledged inconvenience).
Implementing our own json.Marshalers some time ago
(for performance reasons) has made this easier to implement.
Also rename "Interface" fields to more suitable "Variant".
Diffstat (limited to 'liberty-xui.c')
0 files changed, 0 insertions, 0 deletions