From a05aa8a83eba20f1fbace0927eae6e478b462a5a Mon Sep 17 00:00:00 2001 From: mike dupont Date: Mon, 13 Nov 2023 17:36:56 -0500 Subject: [PATCH] removing error, seems to be - --- common/grammar-parser.cpp | 2 +- grammars/ebnf.ebnf | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/common/grammar-parser.cpp b/common/grammar-parser.cpp index f53cb67d068a1..0b4e6b94f75ee 100644 --- a/common/grammar-parser.cpp +++ b/common/grammar-parser.cpp @@ -27,7 +27,7 @@ namespace grammar_parser { static uint32_t get_symbol_id(parse_state & state, const char * src, size_t len) { uint32_t next_id = static_cast(state.symbol_ids.size()); auto result = state.symbol_ids.insert(std::make_pair(std::string(src, len), next_id)); - fprintf(stderr, "added id %s with id %d\n",src,next_id); + fprintf(stderr, "added id:%d wit string:|%s|\n",next_id,std::string(src, len).c_str()); return result.first->second; } diff --git a/grammars/ebnf.ebnf b/grammars/ebnf.ebnf index 8d737d9ea31a1..43ab7d5913a9d 100644 --- a/grammars/ebnf.ebnf +++ b/grammars/ebnf.ebnf @@ -10,8 +10,7 @@ identifier ::= letter ( letter | digit | "_" ) #| "\f" | "\b" S ::= ( " " | "\n" | "\t" | "\r" ) -terminal ::= "'" character - "'" ( character - "'" ) "'" - #| '"' character - '"' ( character - '"' ) '"' +terminal ::= "'" character "'" ( character "'" ) "'" terminator ::= (";" | ".")