1// Copyright 2017 The Fuchsia Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5// No header inclusion guards _sic_ as this may be re-included with
6// different X macro arguments.
7
8#if !defined(TOKEN)
9#define TOKEN(Name)
10#endif
11
12#if !defined(KEYWORD)
13#define KEYWORD(Name, Spelling)
14#endif
15
16// Control and whitespace
17TOKEN(NotAToken)
18TOKEN(EndOfFile)
19TOKEN(Comment)
20TOKEN(DocComment)
21
22// Identifiers and constants
23TOKEN(Identifier)
24TOKEN(NumericLiteral)
25TOKEN(StringLiteral)
26
27// Punctuation.
28TOKEN(LeftParen)
29TOKEN(RightParen)
30TOKEN(LeftSquare)
31TOKEN(RightSquare)
32TOKEN(LeftCurly)
33TOKEN(RightCurly)
34TOKEN(LeftAngle)
35TOKEN(RightAngle)
36
37TOKEN(Dot)
38TOKEN(Comma)
39TOKEN(Semicolon)
40TOKEN(Colon)
41TOKEN(Question)
42TOKEN(Equal)
43TOKEN(Ampersand)
44
45TOKEN(Arrow)
46
47// Keywords
48KEYWORD(As, "as")
49KEYWORD(Library, "library")
50KEYWORD(Using, "using")
51
52KEYWORD(Array, "array")
53KEYWORD(Handle, "handle")
54KEYWORD(Request, "request")
55KEYWORD(String, "string")
56KEYWORD(Vector, "vector")
57
58KEYWORD(Const, "const")
59KEYWORD(Enum, "enum")
60KEYWORD(Interface, "interface")
61KEYWORD(Struct, "struct")
62KEYWORD(Table, "table")
63KEYWORD(Union, "union")
64
65KEYWORD(True, "true")
66KEYWORD(False, "false")
67
68KEYWORD(Reserved, "reserved")
69
70#undef KEYWORD
71#undef TOKEN
72