summaryrefslogtreecommitdiffstats
path: root/source/slang/check.cpp
diff options
context:
space:
mode:
authorjsmall-nvidia <jsmall@nvidia.com>2018-08-22 11:36:02 -0400
committerTim Foley <tfoleyNV@users.noreply.github.com>2018-08-22 08:36:02 -0700
commit6a8ad6eb4cab72c18de48762768e04d08b60a21c (patch)
tree903863bf0154cb73e87c7a70a65c022649c096d3 /source/slang/check.cpp
parent0ce1131ba12f777fbaa40004e0e3e7af89ccf4f0 (diff)
Support for [[vk::push_constant]] (#629)
* Support for attributed [[vk::push_constant]] and [[push_constant]]. Can also use layout(push_constant). * Fix test so matches the expected output. * Add expected output to binding-push-constant-gl.hlsl * Trivial change to force travis rebuild to test the gcc linux build really has a problem.
Diffstat (limited to 'source/slang/check.cpp')
-rw-r--r--source/slang/check.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/slang/check.cpp b/source/slang/check.cpp
index c5ebf7f30..95a958495 100644
--- a/source/slang/check.cpp
+++ b/source/slang/check.cpp
@@ -1959,6 +1959,11 @@ namespace Slang
getSink()->diagnose(attr, Diagnostics::expectedSingleIntArg, attr->name);
}
}
+ else if (attr.As<PushConstantAttribute>())
+ {
+ // Has no args
+ SLANG_ASSERT(attr->args.Count() == 0);
+ }
else
{
if(attr->args.Count() == 0)