From 4cf6b0bb71d06e5850ef93505d71c5203c073772 Mon Sep 17 00:00:00 2001 From: Dmitry Volyntsev Date: Fri, 8 Feb 2019 20:06:05 +0300 Subject: [PATCH] Updated list of reserved keywords. --- njs/njs_lexer_keyword.c | 18 ++---------------- njs/test/njs_expect_test.exp | 4 ++-- 2 files changed, 4 insertions(+), 18 deletions(-) diff --git a/njs/njs_lexer_keyword.c b/njs/njs_lexer_keyword.c index bdffdf08..0b521563 100644 --- a/njs/njs_lexer_keyword.c +++ b/njs/njs_lexer_keyword.c @@ -95,37 +95,23 @@ static const njs_keyword_t njs_keywords[] = { /* Reserved words. */ - { nxt_string("abstract"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("boolean"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("byte"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("char"), NJS_TOKEN_RESERVED, 0 }, + { nxt_string("await"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("class"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("const"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("debugger"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("double"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("enum"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("export"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("extends"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("final"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("float"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("goto"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("implements"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("import"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("int"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("interface"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("long"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("native"), NJS_TOKEN_RESERVED, 0 }, + { nxt_string("let"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("package"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("private"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("protected"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("public"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("short"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("static"), NJS_TOKEN_RESERVED, 0 }, { nxt_string("super"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("synchronized"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("throws"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("transient"), NJS_TOKEN_RESERVED, 0 }, - { nxt_string("volatile"), NJS_TOKEN_RESERVED, 0 }, }; diff --git a/njs/test/njs_expect_test.exp b/njs/test/njs_expect_test.exp index 4ddd2bdf..807e380f 100644 --- a/njs/test/njs_expect_test.exp +++ b/njs/test/njs_expect_test.exp @@ -58,7 +58,7 @@ njs_test { # Global completions, yes njs_test { {"\t\ty" - "\a\r\nDisplay all*possibilities? (y or n)*abstract"} + "\a\r\nDisplay all*possibilities? (y or n)*await"} } # Global completions, single partial match @@ -130,7 +130,7 @@ njs_test { {"var a = 1; var aa = 2\r\n" "var a = 1; var aa = 2\r\nundefined\r\n>> "} {"a\t\t" - "a*aa*abstract"} + "a*aa*arguments*await"} } njs_test { -- 2.47.3