summaryrefslogtreecommitdiffstats
path: root/source/slang/slang-check-decl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'source/slang/slang-check-decl.cpp')
-rw-r--r--source/slang/slang-check-decl.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/source/slang/slang-check-decl.cpp b/source/slang/slang-check-decl.cpp
index 6d8788b4f..9c77303b9 100644
--- a/source/slang/slang-check-decl.cpp
+++ b/source/slang/slang-check-decl.cpp
@@ -14471,6 +14471,15 @@ VarDeclBase* getTrailingUnsizedArrayElement(
return nullptr;
}
+bool isImmutableBufferType(Type* type)
+{
+ if (as<UniformParameterGroupType>(type))
+ return true;
+ if (auto resourceType = as<ResourceType>(type))
+ return resourceType->getAccess() == SLANG_RESOURCE_ACCESS_READ;
+ return false;
+}
+
bool isOpaqueHandleType(Type* type)
{
while (auto modifiedType = as<ModifiedType>(type))