hachem.wtf
aboutsummaryrefslogtreecommitdiff
path: root/sfinae.y
diff options
context:
space:
mode:
Diffstat (limited to 'sfinae.y')
-rw-r--r--sfinae.y3
1 files changed, 3 insertions, 0 deletions
diff --git a/sfinae.y b/sfinae.y
index ca3121d..0d7f0ee 100644
--- a/sfinae.y
+++ b/sfinae.y
@@ -17,6 +17,7 @@ void yyerror(const char* message);
%token TOK_COLONCOLON
%token TOK_EMIT
+%token TOK_STATIC_ASSERT
%token TOK_COMMIT
%token TOK_VOID
%token TOK_INT32
@@ -61,6 +62,8 @@ statements
statement
: TOK_COLONCOLON TOK_EMIT '<' type '>' TOK_COLONCOLON TOK_COMMIT
{ $$ = node_unary(STMT_EMIT, $4); }
+ | TOK_COLONCOLON TOK_STATIC_ASSERT '<' condition '>' TOK_COLONCOLON TOK_COMMIT
+ { $$ = node_unary(STMT_STATIC_ASSERT, $4); }
;
type