I have a binary in src/bin that generates documentation that I thought I could somehow include in for example lib.rs
.
The problem with this is that said binary depends on a module from the project.
The reason is that said binary serializes some structs defined in the project (and displays these json-serialized structs) in the generated doc comments.
So.. to generate the doc comments needed in lib.rs
, first, the crate has to be built, so I have a sort of circular dependency.
Is it possible to solve this by somehow doing two passes (without increasing compilation time noticeably)?
Or am I forced to move the relevant structs out to a new crate?