This is an automated email from the ASF dual-hosted git repository. morningman pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/incubator-doris.git
The following commit(s) were added to refs/heads/master by this push: new 90eaa51 [SQL][JCUP]Reduce conflict of sql_parser.cup (#4177) 90eaa51 is described below commit 90eaa514ba0de3bc63af3eca23db3b10cadf3512 Author: Zhengguo Yang <780531...@qq.com> AuthorDate: Tue Jul 28 10:04:50 2020 +0800 [SQL][JCUP]Reduce conflict of sql_parser.cup (#4177) Fix the Shift/Reduce conflict in cup file #4176 --- fe/fe-core/pom.xml | 2 +- fe/fe-core/src/main/cup/readme | 3 +++ fe/fe-core/src/main/cup/sql_parser.cup | 5 +++++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/fe/fe-core/pom.xml b/fe/fe-core/pom.xml index 7e9518a..a35d2b6 100644 --- a/fe/fe-core/pom.xml +++ b/fe/fe-core/pom.xml @@ -458,7 +458,7 @@ under the License. <!--<cupDefinition>${doris.home}/gensrc/parser/sql_parser.cup</cupDefinition>--> <className>SqlParser</className> <symbolsName>SqlParserSymbols</symbolsName> - <expectedConflicts>6</expectedConflicts> + <expectedConflicts>0</expectedConflicts> <!--<outputDirectory>src/main/java</outputDirectory>--> </configuration> </plugin> diff --git a/fe/fe-core/src/main/cup/readme b/fe/fe-core/src/main/cup/readme new file mode 100644 index 0000000..f9ad4a9 --- /dev/null +++ b/fe/fe-core/src/main/cup/readme @@ -0,0 +1,3 @@ +If you want to modify this file, it is recommended to read the cup documentation +(http://www2.cs.tum.edu/projects/cup/docs.php) first. +Please pay attention to and resolve the conflicts after the modification. \ No newline at end of file diff --git a/fe/fe-core/src/main/cup/sql_parser.cup b/fe/fe-core/src/main/cup/sql_parser.cup index 6f40dfe..8870ae3 100644 --- a/fe/fe-core/src/main/cup/sql_parser.cup +++ b/fe/fe-core/src/main/cup/sql_parser.cup @@ -473,6 +473,10 @@ nonterminal Boolean opt_tmp; nonterminal OutFileClause opt_outfile; +precedence nonassoc COMMA; +precedence nonassoc STRING_LITERAL; +precedence nonassoc KW_COLUMNS; +precedence nonassoc KW_WITH; precedence left KW_FULL, KW_MERGE; precedence left DOT; precedence left SET_VAR; @@ -496,6 +500,7 @@ precedence left KW_OVER; precedence left KW_PARTITION; precedence left KW_PARTITIONS; precedence right KW_TEMPORARY; +precedence right LBRACKET; start with stmts; --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org