shader-slang / slang

Making it easier to work with shaders
MIT License
2.05k stars 175 forks source link

Will Slang support `using` for type aliasing? #4474

Closed chaoticbob closed 2 months ago

chaoticbob commented 3 months ago

I saw in the tests that Slang supports typedef for type aliasing. But I couldn't find anything about using in the docs or the tests. Curious if using will be supported?

dubiousconst282 commented 3 months ago

I think this is already covered by typealias A = B;

jkwak-work commented 3 months ago

I think the user can alias using to typealias with define macro like this,

#define using typealias
bmillsNV commented 3 months ago

@chaoticbob looks like this has been answered. Need anything else?

chaoticbob commented 2 months ago

Thanks!

Aliasing and aliasing directive. I love it.

@bmillsNV All good to go, closing!