diff options
| author | Alexey Bataev <a.bataev@hotmail.com> | 2020-01-08 09:39:44 -0500 |
|---|---|---|
| committer | Alexey Bataev <a.bataev@hotmail.com> | 2020-01-08 10:00:11 -0500 |
| commit | c74a8adda3bc4fc5714aef14cdcfda944d3038a0 (patch) | |
| tree | e36101321bd6aeae91354d00741c17280dd72c2a /clang/lib/Parse/ParseOpenMP.cpp | |
| parent | ead815924e6ebeaf02c31c37ebf7a560b5fdf67b (diff) | |
| download | bcm5719-llvm-c74a8adda3bc4fc5714aef14cdcfda944d3038a0.tar.gz bcm5719-llvm-c74a8adda3bc4fc5714aef14cdcfda944d3038a0.zip | |
[OPENMP]Allow comma in combiner expression.
Use ParseExpression() instead of ParseAssignmentExpression() to allow
commas in combiner expressions.
Diffstat (limited to 'clang/lib/Parse/ParseOpenMP.cpp')
| -rw-r--r-- | clang/lib/Parse/ParseOpenMP.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/clang/lib/Parse/ParseOpenMP.cpp b/clang/lib/Parse/ParseOpenMP.cpp index 31ae3af70b7..24855df334f 100644 --- a/clang/lib/Parse/ParseOpenMP.cpp +++ b/clang/lib/Parse/ParseOpenMP.cpp @@ -343,9 +343,8 @@ Parser::ParseOpenMPDeclareReductionDirective(AccessSpecifier AS) { Scope::OpenMPDirectiveScope); // Parse <combiner> expression. Actions.ActOnOpenMPDeclareReductionCombinerStart(getCurScope(), D); - ExprResult CombinerResult = - Actions.ActOnFinishFullExpr(ParseAssignmentExpression().get(), - D->getLocation(), /*DiscardedValue*/ false); + ExprResult CombinerResult = Actions.ActOnFinishFullExpr( + ParseExpression().get(), D->getLocation(), /*DiscardedValue*/ false); Actions.ActOnOpenMPDeclareReductionCombinerEnd(D, CombinerResult.get()); if (CombinerResult.isInvalid() && Tok.isNot(tok::r_paren) && |

