Description
Since #88038 was resolved with #96630, doctests now run on macro_rules!
even if the macro is not exported.
This could be considered a breaking change -- it did break CI for rayon when this macro example for internal use suddenly became a real test and failed.
The problem is, I can't figure out how to make a working doctest for that, since it's not exported in the public API. What is the intended way to do this? And if there's not really a way to do it, then maybe this change should be reverted so there isn't any break.
I thought of #[cfg_attr(doctest, macro_export)]
, which does make even older Rust try to test it, but that still can't reach the macro because it's still using the non-doctest
build of the crate.
PS: I ended up making unit tests for that rayon macro, which is probably better in that case, but that doesn't answer how non-exported macro tests should work.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status