----- Original Message ----- > From: "Alex Rønne Petersen" <[email protected]> > To: "Tony Young" <[email protected]> > Cc: [email protected] > Sent: Friday, October 19, 2012 12:37:30 AM > Subject: Re: [rust-dev] Should rustdoc include documentation from public > imports? > > On Thu, Oct 18, 2012 at 1:00 PM, Tony Young <[email protected]> wrote: > > I'm not sure where this should be posted so I hope I won't get > > yelled > > at for putting it here. > > > > I'm not sure if this is a fault of incomplete documentation, > > unintuitive behavior on the part of rustdoc or a "feature". > > The problem seems to be that core::f64 is importing > cmath::c_double::* > and then exporting acos which is defined in the latter module. > > I think rustdoc should make this clear in the generated > documentation. >
Documenting reexports (pub use) is a [problem] for rustdoc because figuring out what those items actually represent requires running the full compiler resolution pass, which requires fully compiling all dependencies, and that is not the place of a documentation tool. [problem]: https://github.com/mozilla/rust/issues/3537 One thing we could do is add new rustdoc attributes for manually annotating reexports, either at the reexport site itself or the original definition site. We could also come up with language changes to remove this problem. Certainly toolability is a major goal of Rust and reexports are not tool-friendly. _______________________________________________ Rust-dev mailing list [email protected] https://mail.mozilla.org/listinfo/rust-dev
