Re-export regress to avoid a peer dependency#1009
Open
jeffs wants to merge 1 commit intooxidecomputer:mainfrom
Open
Re-export regress to avoid a peer dependency#1009jeffs wants to merge 1 commit intooxidecomputer:mainfrom
jeffs wants to merge 1 commit intooxidecomputer:mainfrom
Conversation
The import_types! macro emits validation code that referenced ::regress::Regex, forcing every macro consumer to declare regress as a direct dependency. This commit re-exports regress from typify under a #[doc(hidden)] alias, and routes the macro's emitted path through ::typify::regress, so callers can drop the regress entry from Cargo.toml. The default emitted path remains ::regress, so cargo-typify, build.rs users, and direct typify-impl callers are unaffected. A new TypeSpaceSettings::with_regress_crate setter exposes the override.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
The
import_types!macro currently emits validation code that references::regress::Regex, forcing every macro consumer to declareregressas a direct dependency. This commit re-exportsregressfromtypifyunder a#[doc(hidden)]alias, and routes the macro's emitted path through::typify::regress, so callers can drop theregressentry fromCargo.toml.The default emitted path remains
::regress, socargo-typify,build.rsusers, and directtypify-implcallers are unaffected. A newTypeSpaceSettings::with_regress_cratesetter exposes the override.