summaryrefslogtreecommitdiffstats
path: root/source
diff options
context:
space:
mode:
Diffstat (limited to 'source')
-rw-r--r--source/slang/emit.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/slang/emit.cpp b/source/slang/emit.cpp
index 6a10c4f03..5d85b4d57 100644
--- a/source/slang/emit.cpp
+++ b/source/slang/emit.cpp
@@ -1837,6 +1837,10 @@ struct EmitVisitor
void EmitLoopAttributes(RefPtr<StatementSyntaxNode> decl)
{
+ // Don't emit these attributes for GLSL, because it doesn't understand them
+ if (context->shared->target == CodeGenTarget::GLSL)
+ return;
+
// TODO(tfoley): There really ought to be a semantic checking step for attributes,
// that turns abstract syntax into a concrete hierarchy of attribute types (e.g.,
// a specific `LoopModifier` or `UnrollModifier`).