Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose the translation units and parsers for naga frontends #6132

Open
ncthbrt opened this issue Aug 19, 2024 · 3 comments
Open

Expose the translation units and parsers for naga frontends #6132

ncthbrt opened this issue Aug 19, 2024 · 3 comments
Labels
area: api Issues related to API surface naga Shader Translator type: enhancement New feature or request

Comments

@ncthbrt
Copy link

ncthbrt commented Aug 19, 2024

Is your feature request related to a problem? Please describe.

When building tooling or extensions for wgsl, or other shader languages, it'd be very useful to be able to parse the source code without having it be well formed. This would more easily enable for example building a module/import system that allows for cyclical imports of types and functions (useful when for example a main module has types defined in it and a child module needs to refer to the type).

Describe the solution you'd like

Exposing the relevant types that would allow translation units to be manipulated and manually lowered.

Describe alternatives you've considered

Building or vendoring in the naga frontends into the source code.

@teoxoy teoxoy added type: enhancement New feature or request area: api Issues related to API surface naga Shader Translator labels Aug 19, 2024
@teoxoy
Copy link
Member

teoxoy commented Aug 19, 2024

This is the plan for #5713 as well.

@ncthbrt
Copy link
Author

ncthbrt commented Aug 22, 2024

@teoxoy is there any timeline on that? Would be immensely helpful for what I'm building right now in naga oil

@teoxoy
Copy link
Member

teoxoy commented Aug 22, 2024

I'm not aware of any naga maintainer interested in doing this work right now but PRs are welcome!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: api Issues related to API surface naga Shader Translator type: enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants