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

Consider splitting configuration of foreign types into a new generate! macro config key #992

Open
rylev opened this issue Jul 1, 2024 · 1 comment

Comments

@rylev
Copy link
Contributor

rylev commented Jul 1, 2024

In #972 the default for whether bindings would be generated for foreign (i.e., not in the same package as the target world) types was flipped from being generated by default to not. Users could still opt-into generating code for foreign types by using the generate keyword.

The use of a special keyword, however, might not be the most discoverable. Instead we may wish to introduce a new key in the generate! macro.

In short the following...

with: {
    "wasi:io/poll": wasi::io::poll,
    "some:package/my-interface": generate,
},

...would become the following...

with: {
    "wasi:io/poll": wasi::io::poll,
},
generate: [
    "some:package/my-interface"
]
@alexcrichton
Copy link
Member

Seems reasonable to me!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants