diff options
| author | DanielGavin <danielgavin5@hotmail.com> | 2024-08-12 15:10:33 +0200 |
|---|---|---|
| committer | DanielGavin <danielgavin5@hotmail.com> | 2024-08-12 15:10:33 +0200 |
| commit | f17972739e7a69780c1a1d0c814086d70921d86f (patch) | |
| tree | d41152cf8136ded13ff7c582d8083f3451039cc0 /src | |
| parent | 70f0694884dea60a9bd1677c735483c90440751c (diff) | |
Add support for tags in bitfield
Diffstat (limited to 'src')
| -rw-r--r-- | src/odin/printer/visit.odin | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/odin/printer/visit.odin b/src/odin/printer/visit.odin index 8c82a21..09fe9e2 100644 --- a/src/odin/printer/visit.odin +++ b/src/odin/printer/visit.odin @@ -672,6 +672,12 @@ visit_bit_field_fields :: proc( ) } + + if field.tag.text != "" { + document = cons_with_nopl(document, text_token(p, field.tag)) + } + + if (i != len(bit_field_type.fields) - 1 || .Trailing in options) && .Add_Comma in options { document = cons(document, text(",")) } |