Home | History | Annotate | Download | only in Basic
      1 class AttrSubject;
      2 
      3 class Stmt<bit abstract = 0> : AttrSubject {
      4   bit Abstract = abstract;
      5 }
      6 
      7 class DStmt<Stmt base, bit abstract = 0> : Stmt<abstract> {
      8   Stmt Base = base;
      9 }
     10 
     11 // Statements
     12 def NullStmt : Stmt;
     13 def CompoundStmt : Stmt;
     14 def LabelStmt : Stmt;
     15 def AttributedStmt : Stmt;
     16 def IfStmt : Stmt;
     17 def SwitchStmt : Stmt;
     18 def WhileStmt : Stmt;
     19 def DoStmt : Stmt;
     20 def ForStmt : Stmt;
     21 def GotoStmt : Stmt;
     22 def IndirectGotoStmt : Stmt;
     23 def ContinueStmt : Stmt;
     24 def BreakStmt : Stmt;
     25 def ReturnStmt : Stmt;
     26 def DeclStmt  : Stmt;
     27 def SwitchCase : Stmt<1>;
     28 def CaseStmt : DStmt<SwitchCase>;
     29 def DefaultStmt : DStmt<SwitchCase>;
     30 def CapturedStmt : Stmt;
     31 
     32 // Asm statements
     33 def AsmStmt : Stmt<1>;
     34 def GCCAsmStmt : DStmt<AsmStmt>;
     35 def MSAsmStmt : DStmt<AsmStmt>;
     36 
     37 // Obj-C statements
     38 def ObjCAtTryStmt : Stmt;
     39 def ObjCAtCatchStmt : Stmt;
     40 def ObjCAtFinallyStmt : Stmt;
     41 def ObjCAtThrowStmt : Stmt;
     42 def ObjCAtSynchronizedStmt : Stmt;
     43 def ObjCForCollectionStmt : Stmt;
     44 def ObjCAutoreleasePoolStmt : Stmt;
     45 
     46 // C++ statements
     47 def CXXCatchStmt : Stmt;
     48 def CXXTryStmt : Stmt;
     49 def CXXForRangeStmt : Stmt;
     50 
     51 // C++ Coroutines TS statements
     52 def CoroutineBodyStmt : Stmt;
     53 def CoreturnStmt : Stmt;
     54 
     55 // Expressions
     56 def Expr : Stmt<1>;
     57 def PredefinedExpr : DStmt<Expr>;
     58 def DeclRefExpr : DStmt<Expr>;
     59 def IntegerLiteral : DStmt<Expr>;
     60 def FloatingLiteral : DStmt<Expr>;
     61 def ImaginaryLiteral : DStmt<Expr>;
     62 def StringLiteral : DStmt<Expr>;
     63 def CharacterLiteral : DStmt<Expr>;
     64 def ParenExpr : DStmt<Expr>;
     65 def UnaryOperator : DStmt<Expr>;
     66 def OffsetOfExpr : DStmt<Expr>;
     67 def UnaryExprOrTypeTraitExpr : DStmt<Expr>;
     68 def ArraySubscriptExpr : DStmt<Expr>;
     69 def OMPArraySectionExpr : DStmt<Expr>;
     70 def CallExpr : DStmt<Expr>;
     71 def MemberExpr : DStmt<Expr>;
     72 def CastExpr : DStmt<Expr, 1>;
     73 def BinaryOperator : DStmt<Expr>;
     74 def CompoundAssignOperator : DStmt<BinaryOperator>;
     75 def AbstractConditionalOperator : DStmt<Expr, 1>;
     76 def ConditionalOperator : DStmt<AbstractConditionalOperator>;
     77 def BinaryConditionalOperator : DStmt<AbstractConditionalOperator>;
     78 def ImplicitCastExpr : DStmt<CastExpr>;
     79 def ExplicitCastExpr : DStmt<CastExpr, 1>;
     80 def CStyleCastExpr : DStmt<ExplicitCastExpr>;
     81 def CompoundLiteralExpr : DStmt<Expr>;
     82 def ExtVectorElementExpr : DStmt<Expr>;
     83 def InitListExpr : DStmt<Expr>;
     84 def DesignatedInitExpr : DStmt<Expr>;
     85 def DesignatedInitUpdateExpr : DStmt<Expr>;
     86 def ImplicitValueInitExpr : DStmt<Expr>;
     87 def NoInitExpr : DStmt<Expr>;
     88 def ArrayInitLoopExpr : DStmt<Expr>;
     89 def ArrayInitIndexExpr : DStmt<Expr>;
     90 def ParenListExpr : DStmt<Expr>;
     91 def VAArgExpr : DStmt<Expr>;
     92 def GenericSelectionExpr : DStmt<Expr>;
     93 def PseudoObjectExpr : DStmt<Expr>;
     94 
     95 // Atomic expressions
     96 def AtomicExpr : DStmt<Expr>;
     97 
     98 // GNU Extensions.
     99 def AddrLabelExpr : DStmt<Expr>;
    100 def StmtExpr : DStmt<Expr>;
    101 def ChooseExpr : DStmt<Expr>;
    102 def GNUNullExpr : DStmt<Expr>;
    103 
    104 // C++ Expressions.
    105 def CXXOperatorCallExpr : DStmt<CallExpr>;
    106 def CXXMemberCallExpr : DStmt<CallExpr>;
    107 def CXXNamedCastExpr : DStmt<ExplicitCastExpr, 1>;
    108 def CXXStaticCastExpr : DStmt<CXXNamedCastExpr>;
    109 def CXXDynamicCastExpr : DStmt<CXXNamedCastExpr>;
    110 def CXXReinterpretCastExpr : DStmt<CXXNamedCastExpr>;
    111 def CXXConstCastExpr : DStmt<CXXNamedCastExpr>;
    112 def CXXFunctionalCastExpr : DStmt<ExplicitCastExpr>;
    113 def CXXTypeidExpr : DStmt<Expr>;
    114 def UserDefinedLiteral : DStmt<CallExpr>;
    115 def CXXBoolLiteralExpr : DStmt<Expr>;
    116 def CXXNullPtrLiteralExpr : DStmt<Expr>;
    117 def CXXThisExpr : DStmt<Expr>;
    118 def CXXThrowExpr : DStmt<Expr>;
    119 def CXXDefaultArgExpr : DStmt<Expr>;
    120 def CXXDefaultInitExpr : DStmt<Expr>;
    121 def CXXScalarValueInitExpr : DStmt<Expr>;
    122 def CXXStdInitializerListExpr : DStmt<Expr>;
    123 def CXXNewExpr : DStmt<Expr>;
    124 def CXXDeleteExpr : DStmt<Expr>;
    125 def CXXPseudoDestructorExpr : DStmt<Expr>;
    126 def TypeTraitExpr : DStmt<Expr>;
    127 def ArrayTypeTraitExpr : DStmt<Expr>;
    128 def ExpressionTraitExpr : DStmt<Expr>;
    129 def DependentScopeDeclRefExpr : DStmt<Expr>;
    130 def CXXConstructExpr : DStmt<Expr>;
    131 def CXXInheritedCtorInitExpr : DStmt<Expr>;
    132 def CXXBindTemporaryExpr : DStmt<Expr>;
    133 def ExprWithCleanups : DStmt<Expr>;
    134 def CXXTemporaryObjectExpr : DStmt<CXXConstructExpr>;
    135 def CXXUnresolvedConstructExpr : DStmt<Expr>;
    136 def CXXDependentScopeMemberExpr : DStmt<Expr>;
    137 def OverloadExpr : DStmt<Expr, 1>;
    138 def UnresolvedLookupExpr : DStmt<OverloadExpr>;
    139 def UnresolvedMemberExpr : DStmt<OverloadExpr>;
    140 def CXXNoexceptExpr : DStmt<Expr>;
    141 def PackExpansionExpr : DStmt<Expr>;
    142 def SizeOfPackExpr : DStmt<Expr>;
    143 def SubstNonTypeTemplateParmExpr : DStmt<Expr>;
    144 def SubstNonTypeTemplateParmPackExpr : DStmt<Expr>;
    145 def FunctionParmPackExpr : DStmt<Expr>;
    146 def MaterializeTemporaryExpr : DStmt<Expr>;
    147 def LambdaExpr : DStmt<Expr>;
    148 def CXXFoldExpr : DStmt<Expr>;
    149 
    150 // C++ Coroutines TS expressions
    151 def CoroutineSuspendExpr : DStmt<Expr, 1>;
    152 def CoawaitExpr : DStmt<CoroutineSuspendExpr>;
    153 def DependentCoawaitExpr : DStmt<Expr>;
    154 def CoyieldExpr : DStmt<CoroutineSuspendExpr>;
    155 
    156 // Obj-C Expressions.
    157 def ObjCStringLiteral : DStmt<Expr>;
    158 def ObjCBoxedExpr : DStmt<Expr>;
    159 def ObjCArrayLiteral : DStmt<Expr>;
    160 def ObjCDictionaryLiteral : DStmt<Expr>;
    161 def ObjCEncodeExpr : DStmt<Expr>;
    162 def ObjCMessageExpr : DStmt<Expr>;
    163 def ObjCSelectorExpr : DStmt<Expr>;
    164 def ObjCProtocolExpr : DStmt<Expr>;
    165 def ObjCIvarRefExpr : DStmt<Expr>;
    166 def ObjCPropertyRefExpr : DStmt<Expr>;
    167 def ObjCIsaExpr : DStmt<Expr>;
    168 def ObjCIndirectCopyRestoreExpr : DStmt<Expr>;
    169 def ObjCBoolLiteralExpr : DStmt<Expr>;
    170 def ObjCSubscriptRefExpr : DStmt<Expr>;
    171 def ObjCAvailabilityCheckExpr : DStmt<Expr>;
    172 
    173 // Obj-C ARC Expressions.
    174 def ObjCBridgedCastExpr : DStmt<ExplicitCastExpr>;
    175 
    176 // CUDA Expressions.
    177 def CUDAKernelCallExpr : DStmt<CallExpr>;
    178 
    179 // Clang Extensions.
    180 def ShuffleVectorExpr : DStmt<Expr>;
    181 def ConvertVectorExpr : DStmt<Expr>;
    182 def BlockExpr : DStmt<Expr>;
    183 def OpaqueValueExpr : DStmt<Expr>;
    184 def TypoExpr : DStmt<Expr>;
    185 
    186 // Microsoft Extensions.
    187 def MSPropertyRefExpr : DStmt<Expr>;
    188 def MSPropertySubscriptExpr : DStmt<Expr>;
    189 def CXXUuidofExpr : DStmt<Expr>; 
    190 def SEHTryStmt : Stmt;
    191 def SEHExceptStmt : Stmt;
    192 def SEHFinallyStmt : Stmt;
    193 def SEHLeaveStmt : Stmt;
    194 def MSDependentExistsStmt : Stmt;
    195 
    196 // OpenCL Extensions.
    197 def AsTypeExpr : DStmt<Expr>;
    198 
    199 // OpenMP Directives.
    200 def OMPExecutableDirective : Stmt<1>;
    201 def OMPLoopDirective : DStmt<OMPExecutableDirective, 1>;
    202 def OMPParallelDirective : DStmt<OMPExecutableDirective>;
    203 def OMPSimdDirective : DStmt<OMPLoopDirective>;
    204 def OMPForDirective : DStmt<OMPLoopDirective>;
    205 def OMPForSimdDirective : DStmt<OMPLoopDirective>;
    206 def OMPSectionsDirective : DStmt<OMPExecutableDirective>;
    207 def OMPSectionDirective : DStmt<OMPExecutableDirective>;
    208 def OMPSingleDirective : DStmt<OMPExecutableDirective>;
    209 def OMPMasterDirective : DStmt<OMPExecutableDirective>;
    210 def OMPCriticalDirective : DStmt<OMPExecutableDirective>;
    211 def OMPParallelForDirective : DStmt<OMPLoopDirective>;
    212 def OMPParallelForSimdDirective : DStmt<OMPLoopDirective>;
    213 def OMPParallelSectionsDirective : DStmt<OMPExecutableDirective>;
    214 def OMPTaskDirective : DStmt<OMPExecutableDirective>;
    215 def OMPTaskyieldDirective : DStmt<OMPExecutableDirective>;
    216 def OMPBarrierDirective : DStmt<OMPExecutableDirective>;
    217 def OMPTaskwaitDirective : DStmt<OMPExecutableDirective>;
    218 def OMPTaskgroupDirective : DStmt<OMPExecutableDirective>;
    219 def OMPFlushDirective : DStmt<OMPExecutableDirective>;
    220 def OMPOrderedDirective : DStmt<OMPExecutableDirective>;
    221 def OMPAtomicDirective : DStmt<OMPExecutableDirective>;
    222 def OMPTargetDirective : DStmt<OMPExecutableDirective>;
    223 def OMPTargetDataDirective : DStmt<OMPExecutableDirective>;
    224 def OMPTargetEnterDataDirective : DStmt<OMPExecutableDirective>;
    225 def OMPTargetExitDataDirective : DStmt<OMPExecutableDirective>;
    226 def OMPTargetParallelDirective : DStmt<OMPExecutableDirective>;
    227 def OMPTargetParallelForDirective : DStmt<OMPExecutableDirective>;
    228 def OMPTargetUpdateDirective : DStmt<OMPExecutableDirective>;
    229 def OMPTeamsDirective : DStmt<OMPExecutableDirective>;
    230 def OMPCancellationPointDirective : DStmt<OMPExecutableDirective>;
    231 def OMPCancelDirective : DStmt<OMPExecutableDirective>;
    232 def OMPTaskLoopDirective : DStmt<OMPLoopDirective>;
    233 def OMPTaskLoopSimdDirective : DStmt<OMPLoopDirective>;
    234 def OMPDistributeDirective : DStmt<OMPLoopDirective>;
    235 def OMPDistributeParallelForDirective : DStmt<OMPLoopDirective>;
    236 def OMPDistributeParallelForSimdDirective : DStmt<OMPLoopDirective>;
    237 def OMPDistributeSimdDirective : DStmt<OMPLoopDirective>;
    238 def OMPTargetParallelForSimdDirective : DStmt<OMPLoopDirective>;
    239 def OMPTargetSimdDirective : DStmt<OMPLoopDirective>;
    240 def OMPTeamsDistributeDirective : DStmt<OMPLoopDirective>;
    241 def OMPTeamsDistributeSimdDirective : DStmt<OMPLoopDirective>;
    242 def OMPTeamsDistributeParallelForSimdDirective : DStmt<OMPLoopDirective>;
    243 def OMPTeamsDistributeParallelForDirective : DStmt<OMPLoopDirective>;
    244 def OMPTargetTeamsDirective : DStmt<OMPExecutableDirective>;
    245 def OMPTargetTeamsDistributeDirective : DStmt<OMPLoopDirective>;
    246 def OMPTargetTeamsDistributeParallelForDirective : DStmt<OMPLoopDirective>;
    247 def OMPTargetTeamsDistributeParallelForSimdDirective : DStmt<OMPLoopDirective>;
    248 def OMPTargetTeamsDistributeSimdDirective : DStmt<OMPLoopDirective>;
    249