How closely slang follows Microsoft's HLSL development? #3932
-
Hi, I've noticed that generics are different between Microsoft's HLSL and slang. Is there a place where you document all the differences between Microsoft's HLSL and slang? Is a goal of the project to keep slang compatible with Microsoft's HLSL? Or we should expect slang to further diverge from Microsoft's HLSL? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Because both HLSL and Slang are under active development, there will always be divergence between the two languages. For the most part, slang supports HLSL 2021 syntax, though C++-style templates are still on the backlog. Generally, the goal is to stay compatible with HLSL where it makes sense. Iiuc, there are some good arguments for generics over templates when it comes to sensible compilation errors and pre-compilation code analysis. But I believe the intention is to add templates for backwards compatibility with HLSL. |
Beta Was this translation helpful? Give feedback.
Because both HLSL and Slang are under active development, there will always be divergence between the two languages. For the most part, slang supports HLSL 2021 syntax, though C++-style templates are still on the backlog.
Generally, the goal is to stay compatible with HLSL where it makes sense. Iiuc, there are some good arguments for generics over templates when it comes to sensible compilation errors and pre-compilation code analysis. But I believe the intention is to add templates for backwards compatibility with HLSL.