-
Notifications
You must be signed in to change notification settings - Fork 195
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
Implement Clone
for Module
#2013
Conversation
I think we should implement this via a feature flag that's on by default (and run CI with default features off) since @kvark previously mentioned that having these |
I used |
Oh, I think that's even better! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM but let's wait for one more review
I think we should do the opposite and add a feature flag to enable it that's not the default, because I think most people that would want to dabble in naga will try to run $ cargo run And this will cause them to be able to But either way we should document this feature flag |
I don't particularly understand the problem, calling
This PR is specifically made for gfx-rs/wgpu#2903, so not having it on by default doesn't really work. Alternatively, instead of Otherwise I could change gfx-rs/wgpu#2903 to not use
I could add a note under README#development-workflow? |
While And while we can review them, doing so in every PR and pointing it out every time is an added task to the reviewer and some are voluntary so easing their work is always better and it's also unexpected to the contributor because they saw nowhere that the codebase doesn't accept it and suddenly are being told to not do it.
I don't understand the problem. wgpu is a user of naga so it can add to it's No need to implement other traits.
If we do end up following the negative feature flag then yes this would be the preferred place |
Yeah, I don't know what I was thinking, will do that. |
Alright, I changed it to a non-default crate feature and documented it in the crate documentation! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll just wait for @teoxoy to re-review since he originally approved it but otherwise it seems good to me, thanks for your contribution.
This comment was marked as resolved.
This comment was marked as resolved.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good; I think the previous cfg(dev)
could have clashed with downstream users possibly setting the cmd line flag --cfg dev
themselves.
Allows
Module
to be cloned.