/src/test/rustdoc/masked.rs

https://gitlab.com/rust-lang/rust · Rust · 30 lines · 12 code · 10 blank · 8 comment · 2 complexity · 27636343182243a7b304348ec0c59333 MD5 · raw file

  1. // aux-build:masked.rs
  2. #![feature(doc_masked)]
  3. #![crate_name = "foo"]
  4. #[doc(masked)]
  5. extern crate masked;
  6. // @!has 'search-index.js' 'masked_method'
  7. // @!has 'foo/struct.String.html' 'MaskedTrait'
  8. // @!has 'foo/struct.String.html' 'masked_method'
  9. pub use std::string::String;
  10. // @!has 'foo/trait.Clone.html' 'MaskedStruct'
  11. pub use std::clone::Clone;
  12. // @!has 'foo/struct.MyStruct.html' 'MaskedTrait'
  13. // @!has 'foo/struct.MyStruct.html' 'masked_method'
  14. pub struct MyStruct;
  15. impl masked::MaskedTrait for MyStruct {
  16. fn masked_method() {}
  17. }
  18. // @!has 'foo/trait.MyTrait.html' 'MaskedStruct'
  19. pub trait MyTrait {}
  20. impl MyTrait for masked::MaskedStruct {}