summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--source/slang/slang-ir-specialize-dynamic-associatedtype-lookup.cpp1
-rw-r--r--source/slang/slang.cpp4
2 files changed, 5 insertions, 0 deletions
diff --git a/source/slang/slang-ir-specialize-dynamic-associatedtype-lookup.cpp b/source/slang/slang-ir-specialize-dynamic-associatedtype-lookup.cpp
index a5d19b517..059531107 100644
--- a/source/slang/slang-ir-specialize-dynamic-associatedtype-lookup.cpp
+++ b/source/slang/slang-ir-specialize-dynamic-associatedtype-lookup.cpp
@@ -247,6 +247,7 @@ struct AssociatedTypeLookupSpecializationContext
continue;
use->set(witnessTableIDType);
}
+ sharedContext->sharedBuilderStorage.deduplicateAndRebuildGlobalNumberingMap();
}
}
diff --git a/source/slang/slang.cpp b/source/slang/slang.cpp
index 996b539ee..78f7c7c51 100644
--- a/source/slang/slang.cpp
+++ b/source/slang/slang.cpp
@@ -1062,6 +1062,10 @@ SLANG_NO_THROW SlangResult SLANG_MCALL Linkage::getTypeConformanceWitnessSequent
{
auto subType = asInternal(type);
auto supType = asInternal(interfaceType);
+
+ if (!subType || !supType)
+ return SLANG_FAIL;
+
auto name = getMangledNameForConformanceWitness(subType->getASTBuilder(), subType, supType);
auto interfaceName = getMangledTypeName(supType->getASTBuilder(), supType);
uint32_t resultIndex = 0;