diff options
| author | mat <github@matdoes.dev> | 2022-06-16 20:48:01 -0500 |
|---|---|---|
| committer | mat <github@matdoes.dev> | 2022-06-16 20:48:01 -0500 |
| commit | 4f89f70091962c967a7022e6f293f11a446abc3c (patch) | |
| tree | 9b18ee8cfa160e59cff0ba319e91fdce83e7d3ff /codegen | |
| parent | 5d5441427f21733046a8f4e5671276408f32c27f (diff) | |
| download | azalea-drasl-4f89f70091962c967a7022e6f293f11a446abc3c.tar.xz | |
type -> kind
Diffstat (limited to 'codegen')
| -rw-r--r-- | codegen/lib/code/blocks.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/codegen/lib/code/blocks.py b/codegen/lib/code/blocks.py index f6d6bb4b..4ab4917f 100644 --- a/codegen/lib/code/blocks.py +++ b/codegen/lib/code/blocks.py @@ -103,6 +103,10 @@ def generate_blocks(blocks_burger: dict, blocks_report: dict, ordered_blocks: li ending = property_name.split('_')[-1] if ending.isdigit(): property_name = property_name[:-(len(ending) + 1)] + + # `type` is a reserved keyword, so we use kind instead ¯\_(ツ)_/¯ + if property_name == 'type': + property_name = 'kind' property_struct_names_to_names[property_struct_name] = property_name properties.update(block_properties) |
