refactor(provider-wit-bindgen): macro crate structure #1305
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Feature or Problem
Up until now, dependencies that were exercised by
wasmcloud-wit-provider-bindgen
were required of the downstream binaries that were being used.To make it easier for people to build providers (as they might be surprised by dependencies introduced by the macro), and encourage consistency in the dependencies used, we want to internalize the dependencies that the macro introduces (i.e. hanging them off the macro crate).
Given that Rust has a limitation where macro crates cannot have any other exports, we must create an "umbrella" crate which hosts the macro along with other dependencies, and use that.
This commit modifies the macro crate structure, renaming out
wasmcloud-provider-wit-bindgen
to
wasmcloud-provider-wit-bindgen-macro
, and keepingwasmcloud-provider-wit-bindgen
as the top level macro without breaking backwards compatibility.This commit does not internalize the deps, it only goes as far as to make the structure where it is possible.
Related Issues
Release Information
Consumer Impact
Testing
Unit Test(s)
Acceptance or Integration
Manual Verification