@@ -182,6 +182,7 @@ class Preprocessor;
182
182
class PseudoDestructorTypeStorage;
183
183
class PseudoObjectExpr;
184
184
class QualType;
185
+ class SemaHLSL;
185
186
class SemaOpenACC;
186
187
class StandardConversionSequence;
187
188
class Stmt;
@@ -465,9 +466,8 @@ class Sema final : public SemaBase {
465
466
// 36. FixIt Helpers (SemaFixItUtils.cpp)
466
467
// 37. Name Lookup for RISC-V Vector Intrinsic (SemaRISCVVectorLookup.cpp)
467
468
// 38. CUDA (SemaCUDA.cpp)
468
- // 39. HLSL Constructs (SemaHLSL.cpp)
469
- // 40. OpenMP Directives and Clauses (SemaOpenMP.cpp)
470
- // 41. SYCL Constructs (SemaSYCL.cpp)
469
+ // 39. OpenMP Directives and Clauses (SemaOpenMP.cpp)
470
+ // 40. SYCL Constructs (SemaSYCL.cpp)
471
471
472
472
/// \name Semantic Analysis
473
473
/// Implementations are in Sema.cpp
@@ -964,6 +964,11 @@ class Sema final : public SemaBase {
964
964
/// CurContext - This is the current declaration context of parsing.
965
965
DeclContext *CurContext;
966
966
967
+ SemaHLSL &HLSL() {
968
+ assert(HLSLPtr);
969
+ return *HLSLPtr;
970
+ }
971
+
967
972
SemaOpenACC &OpenACC() {
968
973
assert(OpenACCPtr);
969
974
return *OpenACCPtr;
@@ -999,6 +1004,7 @@ class Sema final : public SemaBase {
999
1004
1000
1005
mutable IdentifierInfo *Ident_super;
1001
1006
1007
+ std::unique_ptr<SemaHLSL> HLSLPtr;
1002
1008
std::unique_ptr<SemaOpenACC> OpenACCPtr;
1003
1009
1004
1010
///@}
@@ -1967,6 +1973,11 @@ class Sema final : public SemaBase {
1967
1973
bool CheckFunctionCall(FunctionDecl *FDecl, CallExpr *TheCall,
1968
1974
const FunctionProtoType *Proto);
1969
1975
1976
+ bool BuiltinVectorMath(CallExpr *TheCall, QualType &Res);
1977
+ bool BuiltinVectorToScalarMath(CallExpr *TheCall);
1978
+
1979
+ bool CheckHLSLBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall);
1980
+
1970
1981
private:
1971
1982
void CheckArrayAccess(const Expr *BaseExpr, const Expr *IndexExpr,
1972
1983
const ArraySubscriptExpr *ASE = nullptr,
@@ -13145,29 +13156,6 @@ class Sema final : public SemaBase {
13145
13156
//
13146
13157
//
13147
13158
13148
- /// \name HLSL Constructs
13149
- /// Implementations are in SemaHLSL.cpp
13150
- ///@{
13151
-
13152
- public:
13153
- Decl *ActOnStartHLSLBuffer(Scope *BufferScope, bool CBuffer,
13154
- SourceLocation KwLoc, IdentifierInfo *Ident,
13155
- SourceLocation IdentLoc, SourceLocation LBrace);
13156
- void ActOnFinishHLSLBuffer(Decl *Dcl, SourceLocation RBrace);
13157
-
13158
- bool CheckHLSLBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall);
13159
-
13160
- bool BuiltinVectorMath(CallExpr *TheCall, QualType &Res);
13161
- bool BuiltinVectorToScalarMath(CallExpr *TheCall);
13162
-
13163
- ///@}
13164
-
13165
- //
13166
- //
13167
- // -------------------------------------------------------------------------
13168
- //
13169
- //
13170
-
13171
13159
/// \name OpenMP Directives and Clauses
13172
13160
/// Implementations are in SemaOpenMP.cpp
13173
13161
///@{
0 commit comments