summaryrefslogtreecommitdiffstats
path: root/source/slang/slang-check-conversion.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'source/slang/slang-check-conversion.cpp')
-rw-r--r--source/slang/slang-check-conversion.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/source/slang/slang-check-conversion.cpp b/source/slang/slang-check-conversion.cpp
index fcbc83673..41355597f 100644
--- a/source/slang/slang-check-conversion.cpp
+++ b/source/slang/slang-check-conversion.cpp
@@ -250,6 +250,13 @@ bool SemanticsVisitor::isCStyleType(Type* type, HashSet<Type*>& isVisit)
as<PtrType>(type))
return cacheResult(true);
+ // Slang 2026 language fix: an interface type is not C-style.
+ if (isSlang2026OrLater(this))
+ {
+ // TODO: some/dyn types are also not C-style.
+ if (isDeclRefTypeOf<InterfaceDecl>(type))
+ return cacheResult(false);
+ }
// A tuple type is C-style if all of its members are C-style.
if (auto tupleType = as<TupleType>(type))