|
@@ -2446,25 +2446,25 @@ static CXXRecordDecl *CreateRayDescStruct(clang::ASTContext &context,
|
|
|
return rayDescDecl;
|
|
|
}
|
|
|
|
|
|
-// struct BuiltInTriangleIntersectionAttributes
|
|
|
-// {
|
|
|
-// float2 barycentrics;
|
|
|
-// };
|
|
|
-static void AddBuiltInTriangleIntersectionAttributes(ASTContext& context, QualType baryType) {
|
|
|
- DeclContext *curDC = context.getTranslationUnitDecl();
|
|
|
- IdentifierInfo &attributesId =
|
|
|
- context.Idents.get(StringRef("BuiltInTriangleIntersectionAttributes"),
|
|
|
- tok::TokenKind::identifier);
|
|
|
+// struct BuiltInTriangleIntersectionAttributes
|
|
|
+// {
|
|
|
+// float2 barycentrics;
|
|
|
+// };
|
|
|
+static void AddBuiltInTriangleIntersectionAttributes(ASTContext& context, QualType baryType) {
|
|
|
+ DeclContext *curDC = context.getTranslationUnitDecl();
|
|
|
+ IdentifierInfo &attributesId =
|
|
|
+ context.Idents.get(StringRef("BuiltInTriangleIntersectionAttributes"),
|
|
|
+ tok::TokenKind::identifier);
|
|
|
CXXRecordDecl *attributesDecl = CXXRecordDecl::Create(
|
|
|
context, TagTypeKind::TTK_Struct, curDC, NoLoc, NoLoc,
|
|
|
- &attributesId, nullptr, DelayTypeCreationTrue);
|
|
|
- attributesDecl->startDefinition();
|
|
|
- // float2 barycentrics;
|
|
|
- CreateSimpleField(context, attributesDecl, "barycentrics", baryType);
|
|
|
- attributesDecl->completeDefinition();
|
|
|
- attributesDecl->setImplicit(true);
|
|
|
- curDC->addDecl(attributesDecl);
|
|
|
-}
|
|
|
+ &attributesId, nullptr, DelayTypeCreationTrue);
|
|
|
+ attributesDecl->startDefinition();
|
|
|
+ // float2 barycentrics;
|
|
|
+ CreateSimpleField(context, attributesDecl, "barycentrics", baryType);
|
|
|
+ attributesDecl->completeDefinition();
|
|
|
+ attributesDecl->setImplicit(true);
|
|
|
+ curDC->addDecl(attributesDecl);
|
|
|
+}
|
|
|
|
|
|
//
|
|
|
// This is similar to clang/Analysis/CallGraph, but the following differences
|