summaryrefslogtreecommitdiffstats
path: root/clang/lib/Parse/ParseOpenMP.cpp
diff options
context:
space:
mode:
authorAlexey Bataev <a.bataev@hotmail.com>2015-08-20 12:15:57 +0000
committerAlexey Bataev <a.bataev@hotmail.com>2015-08-20 12:15:57 +0000
commit1185e193a486881c5685e581e818f6f667b61bfb (patch)
treeee262bf2833f269cfb4679751a298fa888579550 /clang/lib/Parse/ParseOpenMP.cpp
parentc6a144b0aaa0df954423a13c1804bfe0538bd21f (diff)
downloadbcm5719-llvm-1185e193a486881c5685e581e818f6f667b61bfb.tar.gz
bcm5719-llvm-1185e193a486881c5685e581e818f6f667b61bfb.zip
[OPENMP 4.1] Allow to use 'uval' and 'ref' modifiers for reference types only.
Standard allows to use 'uval' and 'ref' modifiers in 'linear' clause for variables with reference types only. Added check for it and modified test. llvm-svn: 245556
Diffstat (limited to 'clang/lib/Parse/ParseOpenMP.cpp')
-rw-r--r--clang/lib/Parse/ParseOpenMP.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/clang/lib/Parse/ParseOpenMP.cpp b/clang/lib/Parse/ParseOpenMP.cpp
index e7966d42a50..beb38e10f2a 100644
--- a/clang/lib/Parse/ParseOpenMP.cpp
+++ b/clang/lib/Parse/ParseOpenMP.cpp
@@ -785,9 +785,8 @@ OMPClause *Parser::ParseOpenMPVarListClause(OpenMPClauseKind Kind) {
} else if (Kind == OMPC_linear) {
// Try to parse modifier if any.
if (Tok.is(tok::identifier) && PP.LookAhead(0).is(tok::l_paren)) {
- StringRef TokSpelling = PP.getSpelling(Tok);
LinearModifier = static_cast<OpenMPLinearClauseKind>(
- getOpenMPSimpleClauseType(Kind, TokSpelling));
+ getOpenMPSimpleClauseType(Kind, PP.getSpelling(Tok)));
DepLinLoc = ConsumeToken();
LinearT.consumeOpen();
NeedRParenForLinear = true;
OpenPOWER on IntegriCloud