@@ -1087,11 +1087,13 @@ class OpenACCCopyClause final
10871087 : public OpenACCClauseWithVarList,
10881088 private llvm::TrailingObjects<OpenACCCopyClause, Expr *> {
10891089 friend TrailingObjects;
1090+ OpenACCModifierKind Modifiers;
10901091
10911092 OpenACCCopyClause (OpenACCClauseKind Spelling, SourceLocation BeginLoc,
1092- SourceLocation LParenLoc, ArrayRef<Expr *> VarList,
1093- SourceLocation EndLoc)
1094- : OpenACCClauseWithVarList(Spelling, BeginLoc, LParenLoc, EndLoc) {
1093+ SourceLocation LParenLoc, OpenACCModifierKind Mods,
1094+ ArrayRef<Expr *> VarList, SourceLocation EndLoc)
1095+ : OpenACCClauseWithVarList(Spelling, BeginLoc, LParenLoc, EndLoc),
1096+ Modifiers (Mods) {
10951097 assert ((Spelling == OpenACCClauseKind::Copy ||
10961098 Spelling == OpenACCClauseKind::PCopy ||
10971099 Spelling == OpenACCClauseKind::PresentOrCopy) &&
@@ -1110,20 +1112,23 @@ class OpenACCCopyClause final
11101112 static OpenACCCopyClause *
11111113 Create (const ASTContext &C, OpenACCClauseKind Spelling,
11121114 SourceLocation BeginLoc, SourceLocation LParenLoc,
1113- ArrayRef<Expr *> VarList, SourceLocation EndLoc);
1115+ OpenACCModifierKind Mods, ArrayRef<Expr *> VarList,
1116+ SourceLocation EndLoc);
1117+
1118+ OpenACCModifierKind getModifierList () const { return Modifiers; }
11141119};
11151120
11161121class OpenACCCopyInClause final
11171122 : public OpenACCClauseWithVarList,
11181123 private llvm::TrailingObjects<OpenACCCopyInClause, Expr *> {
11191124 friend TrailingObjects;
1120- bool IsReadOnly ;
1125+ OpenACCModifierKind Modifiers ;
11211126
11221127 OpenACCCopyInClause (OpenACCClauseKind Spelling, SourceLocation BeginLoc,
1123- SourceLocation LParenLoc, bool IsReadOnly ,
1128+ SourceLocation LParenLoc, OpenACCModifierKind Mods ,
11241129 ArrayRef<Expr *> VarList, SourceLocation EndLoc)
11251130 : OpenACCClauseWithVarList(Spelling, BeginLoc, LParenLoc, EndLoc),
1126- IsReadOnly (IsReadOnly ) {
1131+ Modifiers (Mods ) {
11271132 assert ((Spelling == OpenACCClauseKind::CopyIn ||
11281133 Spelling == OpenACCClauseKind::PCopyIn ||
11291134 Spelling == OpenACCClauseKind::PresentOrCopyIn) &&
@@ -1139,24 +1144,25 @@ class OpenACCCopyInClause final
11391144 C->getClauseKind () == OpenACCClauseKind::PCopyIn ||
11401145 C->getClauseKind () == OpenACCClauseKind::PresentOrCopyIn;
11411146 }
1142- bool isReadOnly () const { return IsReadOnly ; }
1147+ OpenACCModifierKind getModifierList () const { return Modifiers ; }
11431148 static OpenACCCopyInClause *
11441149 Create (const ASTContext &C, OpenACCClauseKind Spelling,
1145- SourceLocation BeginLoc, SourceLocation LParenLoc, bool IsReadOnly,
1146- ArrayRef<Expr *> VarList, SourceLocation EndLoc);
1150+ SourceLocation BeginLoc, SourceLocation LParenLoc,
1151+ OpenACCModifierKind Mods, ArrayRef<Expr *> VarList,
1152+ SourceLocation EndLoc);
11471153};
11481154
11491155class OpenACCCopyOutClause final
11501156 : public OpenACCClauseWithVarList,
11511157 private llvm::TrailingObjects<OpenACCCopyOutClause, Expr *> {
11521158 friend TrailingObjects;
1153- bool IsZero ;
1159+ OpenACCModifierKind Modifiers ;
11541160
11551161 OpenACCCopyOutClause (OpenACCClauseKind Spelling, SourceLocation BeginLoc,
1156- SourceLocation LParenLoc, bool IsZero ,
1162+ SourceLocation LParenLoc, OpenACCModifierKind Mods ,
11571163 ArrayRef<Expr *> VarList, SourceLocation EndLoc)
11581164 : OpenACCClauseWithVarList(Spelling, BeginLoc, LParenLoc, EndLoc),
1159- IsZero (IsZero ) {
1165+ Modifiers (Mods ) {
11601166 assert ((Spelling == OpenACCClauseKind::CopyOut ||
11611167 Spelling == OpenACCClauseKind::PCopyOut ||
11621168 Spelling == OpenACCClauseKind::PresentOrCopyOut) &&
@@ -1172,24 +1178,25 @@ class OpenACCCopyOutClause final
11721178 C->getClauseKind () == OpenACCClauseKind::PCopyOut ||
11731179 C->getClauseKind () == OpenACCClauseKind::PresentOrCopyOut;
11741180 }
1175- bool isZero () const { return IsZero ; }
1181+ OpenACCModifierKind getModifierList () const { return Modifiers ; }
11761182 static OpenACCCopyOutClause *
11771183 Create (const ASTContext &C, OpenACCClauseKind Spelling,
1178- SourceLocation BeginLoc, SourceLocation LParenLoc, bool IsZero,
1179- ArrayRef<Expr *> VarList, SourceLocation EndLoc);
1184+ SourceLocation BeginLoc, SourceLocation LParenLoc,
1185+ OpenACCModifierKind Mods, ArrayRef<Expr *> VarList,
1186+ SourceLocation EndLoc);
11801187};
11811188
11821189class OpenACCCreateClause final
11831190 : public OpenACCClauseWithVarList,
11841191 private llvm::TrailingObjects<OpenACCCreateClause, Expr *> {
11851192 friend TrailingObjects;
1186- bool IsZero ;
1193+ OpenACCModifierKind Modifiers ;
11871194
11881195 OpenACCCreateClause (OpenACCClauseKind Spelling, SourceLocation BeginLoc,
1189- SourceLocation LParenLoc, bool IsZero ,
1196+ SourceLocation LParenLoc, OpenACCModifierKind Mods ,
11901197 ArrayRef<Expr *> VarList, SourceLocation EndLoc)
11911198 : OpenACCClauseWithVarList(Spelling, BeginLoc, LParenLoc, EndLoc),
1192- IsZero (IsZero ) {
1199+ Modifiers (Mods ) {
11931200 assert ((Spelling == OpenACCClauseKind::Create ||
11941201 Spelling == OpenACCClauseKind::PCreate ||
11951202 Spelling == OpenACCClauseKind::PresentOrCreate) &&
@@ -1205,11 +1212,12 @@ class OpenACCCreateClause final
12051212 C->getClauseKind () == OpenACCClauseKind::PCreate ||
12061213 C->getClauseKind () == OpenACCClauseKind::PresentOrCreate;
12071214 }
1208- bool isZero () const { return IsZero ; }
1215+ OpenACCModifierKind getModifierList () const { return Modifiers ; }
12091216 static OpenACCCreateClause *
12101217 Create (const ASTContext &C, OpenACCClauseKind Spelling,
1211- SourceLocation BeginLoc, SourceLocation LParenLoc, bool IsZero,
1212- ArrayRef<Expr *> VarList, SourceLocation EndLoc);
1218+ SourceLocation BeginLoc, SourceLocation LParenLoc,
1219+ OpenACCModifierKind Mods, ArrayRef<Expr *> VarList,
1220+ SourceLocation EndLoc);
12131221};
12141222
12151223class OpenACCReductionClause final
0 commit comments