[−][src]Crate doc_cfg_example
This example shows how to use the #[doc_cfg(..)]
attribute.
Run cargo doc --features unstable-doc-cfg --open
to generate. It seems to
work on stable rustc as of 1.32 but this is probably an unintended bug and
you shouldn't count on the unstable-doc-cfg
feature working anywhere but
with a nightly toolchain.
Check the source code of this example to see how it all works, or clone it from github and try it yourself.
Functions
boring_old_fn | A plain old normal function. |
cool_nonportable_fn | [nintendo64 and sse Mark something as only available on fancy platforms! |
feature_gated_fn | [feature="my-fancy-feature" You can also display a message that differs from the actual |