aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorHimbeer <himbeer@disroot.org>2024-09-15 18:01:14 +0200
committerHimbeer <himbeer@disroot.org>2024-09-15 18:01:14 +0200
commite4e380156a220fc2285580f3c0d873031df2aa77 (patch)
treeefb37303df5ca8c1d23bcaf8d35e9677f57fe6ea /doc
parent1481f19817f19412880a9dc245e06c86a137f38b (diff)
Define syntax for specifying enum tag types
Diffstat (limited to 'doc')
-rw-r--r--doc/grammar.txt2
1 files changed, 1 insertions, 1 deletions
diff --git a/doc/grammar.txt b/doc/grammar.txt
index a3b2b7c..6ccf3ba 100644
--- a/doc/grammar.txt
+++ b/doc/grammar.txt
@@ -63,7 +63,7 @@ float := "float32" | "float64"
array := "[" expression "]" type
slice := "[]" type
struct := "struct" "{" fields "}"
-enum := "enum" [ expression ] "{" ( NAME ), "}"
+enum := "enum" [ integer ] [ "=" expression ] "{" ( NAME ), "}"
union := "union" [ type ] "{" fields "}"
fields := ( NAME type ),