/src/test/rustdoc/inline_local/glob-private.rs

https://gitlab.com/jianglu/rust · Rust · 52 lines · 11 code · 7 blank · 34 comment · 0 complexity · 668c53077edfde562ee7a261d0293271 MD5 · raw file

  1. // Copyright 2016 The Rust Project Developers. See the COPYRIGHT
  2. // file at the top-level directory of this distribution and at
  3. // http://rust-lang.org/COPYRIGHT.
  4. //
  5. // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
  6. // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
  7. // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
  8. // option. This file may not be copied, modified, or distributed
  9. // except according to those terms.
  10. #![crate_name = "foo"]
  11. mod mod1 {
  12. mod mod2 {
  13. pub struct Mod2Public;
  14. struct Mod2Private;
  15. }
  16. pub use self::mod2::*;
  17. pub struct Mod1Public;
  18. struct Mod1Private;
  19. }
  20. pub use mod1::*;
  21. // @has foo/index.html
  22. // @!has - "mod1"
  23. // @has - "Mod1Public"
  24. // @!has - "Mod1Private"
  25. // @!has - "mod2"
  26. // @has - "Mod2Public"
  27. // @!has - "Mod2Private"
  28. // @has foo/struct.Mod1Public.html
  29. // @!has foo/struct.Mod1Private.html
  30. // @has foo/struct.Mod2Public.html
  31. // @!has foo/struct.Mod2Private.html
  32. // @has-dir foo/mod1
  33. // @!has foo/mod1/index.html
  34. // @has foo/mod1/struct.Mod1Public.html
  35. // @!has foo/mod1/struct.Mod1Private.html
  36. // @!has foo/mod1/struct.Mod2Public.html
  37. // @!has foo/mod1/struct.Mod2Private.html
  38. // @has-dir foo/mod1/mod2
  39. // @!has foo/mod1/mod2/index.html
  40. // @has foo/mod1/mod2/struct.Mod2Public.html
  41. // @!has foo/mod1/mod2/struct.Mod2Private.html
  42. // @!has-dir foo/mod2
  43. // @!has foo/mod2/index.html
  44. // @!has foo/mod2/struct.Mod2Public.html
  45. // @!has foo/mod2/struct.Mod2Private.html