From af70651a4843b16dd24e14b5cedffe399ebeb862 Mon Sep 17 00:00:00 2001 From: Yong He Date: Sat, 20 Aug 2022 01:03:06 -0700 Subject: Call `gfx` in slang program. (#2370) --- source/slang/slang-ir-com-interface.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'source/slang/slang-ir-com-interface.cpp') diff --git a/source/slang/slang-ir-com-interface.cpp b/source/slang/slang-ir-com-interface.cpp index d9d54d9d2..3e52054cd 100644 --- a/source/slang/slang-ir-com-interface.cpp +++ b/source/slang/slang-ir-com-interface.cpp @@ -16,6 +16,8 @@ static bool _canReplace(IRUse* use) case kIROp_WitnessTableType: case kIROp_RTTIPointerType: case kIROp_RTTIHandleType: + case kIROp_ComPtrType: + case kIROp_NativePtrType: { // Don't replace return false; @@ -25,7 +27,6 @@ static bool _canReplace(IRUse* use) // Appears replacable. break; } - case kIROp_ComPtrType: case kIROp_PtrType: { // We can have ** and ComPtr*. @@ -98,7 +99,7 @@ void lowerComInterfaces(IRModule* module, ArtifactStyle artifactStyle, Diagnosti // so has to be a raw pointer IRType* result = (artifactStyle == ArtifactStyle::Host) ? static_cast(builder.getComPtrType(comIntf)) : - static_cast(builder.getPtrType(comIntf)); + static_cast(builder.getNativePtrType(comIntf)); // Go through replacing all of the replacable uses for (auto use : uses) -- cgit v1.2.3