microsoft / microsoft/DirectXShaderCompiler
[SPIR-V] can't decorate a struct or type properly
Open
@luciechoi is already working on this.
Since Apr 17, 2026.
bug
needs-triage
spirv
- Dominant language
- C++
- Stars
- 3.7k
- Forks
- 900
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 44
Description
Doing this:
// declare a GLSL-like block
struct [[vk::ext_decorate(/* Block */ 2)]] SpheresShared
{
Sphere spheres[9];
};
produces an error saying error: 'ext_decorate' attribute only applies to functions, variables, parameters, fields, and types
godbolt: https://godbolt.org/z/596Pcreaa
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.