Skip to content
This repository has been archived by the owner on Nov 30, 2022. It is now read-only.

Fix macro usage in macros #161

Merged
merged 1 commit into from
Jun 7, 2022

Conversation

tcharding
Copy link
Member

@tcharding tcharding commented Jun 7, 2022

Currently we have macros that call other macros without a fully qualified path, this breaks some usage of the macros downstream because macro calls that should be opaque require importing.

Fix macro usage in macros by using $crate:: fully qualified path.

Done in preparation for removing extern crate and macro_use in rust-bitcoin (since we have edition 2018). See rust-bitcoin/rust-bitcoin#1041 for demonstration of using the changes proposed here.

Currently we have macros that call other macros without a fully
qualified path, this breaks some usage of the macros downstream because
macro calls that should be opaque require importing.

Fix macro usage in macros by using `$crate::` fully qualified path.
Copy link
Member

@apoelstra apoelstra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK aba33d1

@apoelstra
Copy link
Member

Thanks for chasing this down! Macro usability is really irritating to test.

@apoelstra apoelstra merged commit d0ec620 into rust-bitcoin:master Jun 7, 2022
@tcharding tcharding deleted the 06-07-fix-macros branch June 22, 2022 06:45
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants