blob: 5dd64b96ae81aa0a6e8ebeb1ad84ba358289fae8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
// slang-token.cpp
#include "slang-token.h"
// #include <assert.h>
namespace Slang
{
char const* TokenTypeToString(TokenType type)
{
switch (type)
{
default: SLANG_ASSERT(!"unexpected"); return "<uknown>";
#define TOKEN(NAME, DESC) \
case TokenType::NAME: return DESC;
#include "slang-token-defs.h"
}
}
} // namespace Slang
|