Export macro with dependency

I have a macro_rules! macro which expands to something that refers to a dependency of the crate in which it is defined.

Is it possible to use this macro in a client crate, without that crate adding the same dependency? I suspect that the answer is 'no', but I'd like to make sure that I'm not missing some trick that makes it possible.

You can pub use your_dependency; -- perhaps with #[doc(hidden)] -- and then your macro can refer to it as $crate::your_dependency::Thing

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.