[njs] Fixed printing AST with recently added tokens.

Dmitry Volyntsev xeioex at nginx.com
Fri Jun 18 15:07:40 UTC 2021


details:   https://hg.nginx.org/njs/rev/9aed07704f30
branches:  
changeset: 1665:9aed07704f30
user:      Dmitry Volyntsev <xeioex at nginx.com>
date:      Fri Jun 18 15:01:13 2021 +0000
description:
Fixed printing AST with recently added tokens.

diffstat:

 src/njs_parser.c |  3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diffs (27 lines):

diff -r d66e00e55b96 -r 9aed07704f30 src/njs_parser.c
--- a/src/njs_parser.c	Fri Jun 18 15:01:12 2021 +0000
+++ b/src/njs_parser.c	Fri Jun 18 15:01:13 2021 +0000
@@ -8848,6 +8848,7 @@ njs_parser_serialize_node(njs_chb_t *cha
     njs_token_serialize(NJS_TOKEN_PROTO_INIT);
 
     njs_token_serialize(NJS_TOKEN_FUNCTION);
+    njs_token_serialize(NJS_TOKEN_FUNCTION_DECLARATION);
     njs_token_serialize(NJS_TOKEN_FUNCTION_EXPRESSION);
     njs_token_serialize(NJS_TOKEN_FUNCTION_CALL);
     njs_token_serialize(NJS_TOKEN_METHOD_CALL);
@@ -8858,6 +8859,7 @@ njs_parser_serialize_node(njs_chb_t *cha
     njs_token_serialize(NJS_TOKEN_BLOCK);
     njs_token_serialize(NJS_TOKEN_VAR);
     njs_token_serialize(NJS_TOKEN_LET);
+    njs_token_serialize(NJS_TOKEN_CONST);
     njs_token_serialize(NJS_TOKEN_IF);
     njs_token_serialize(NJS_TOKEN_ELSE);
     njs_token_serialize(NJS_TOKEN_BRANCHING);
@@ -8887,7 +8889,6 @@ njs_parser_serialize_node(njs_chb_t *cha
     njs_token_serialize(NJS_TOKEN_META);
     njs_token_serialize(NJS_TOKEN_ASYNC);
     njs_token_serialize(NJS_TOKEN_AWAIT);
-    njs_token_serialize(NJS_TOKEN_CONST);
     njs_token_serialize(NJS_TOKEN_DEBUGGER);
     njs_token_serialize(NJS_TOKEN_ENUM);
 


More information about the nginx-devel mailing list