summaryrefslogtreecommitdiffstats
path: root/source/slang/slang.cpp
diff options
context:
space:
mode:
authorYong He <yonghe@outlook.com>2024-04-30 09:57:54 -0700
committerGitHub <noreply@github.com>2024-04-30 09:57:54 -0700
commitf1221b80c3c5f59ed533147825ea414bef5e9df2 (patch)
tree2b737438f2fe82d40035118a34b6d7074991f5a6 /source/slang/slang.cpp
parent019d68fc14dd006c179417ffdb06827abe089a53 (diff)
Metal: Vertex/Fragment builtin and layouts. (#4044)
* Metal: Vertex/Fragment builtin and layouts. * Fix. * Fix test. * Emit user semantic on vertex/fragment attributes.
Diffstat (limited to 'source/slang/slang.cpp')
-rw-r--r--source/slang/slang.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/slang/slang.cpp b/source/slang/slang.cpp
index 971d6056f..4a446a351 100644
--- a/source/slang/slang.cpp
+++ b/source/slang/slang.cpp
@@ -6445,6 +6445,9 @@ SlangResult EndToEndCompileRequest::isParameterLocationUsed(Int entryPointIndex,
if (SLANG_FAILED(_getEntryPointResult(this, static_cast<int>(entryPointIndex), static_cast<int>(targetIndex), artifact)))
return SLANG_E_INVALID_ARG;
+ if (!artifact)
+ return SLANG_E_NOT_AVAILABLE;
+
// Find a rep
auto metadata = findAssociatedRepresentation<IArtifactPostEmitMetadata>(artifact);
if (!metadata)