about summary refs log tree commit diff
diff options
context:
space:
mode:
authorManish Goregaokar <manishsmail@gmail.com>2016-01-28 00:48:32 +0530
committerManish Goregaokar <manishsmail@gmail.com>2016-01-28 00:48:32 +0530
commit3e56732322fdfa65e640a5bd89f6f38e45e8312d (patch)
tree79781c4efd86d2b668ca71f26418cd3b25b1ad9d
parentcb3680c08028e4cfe241cf7e68a5d8d6e5dbd2d7 (diff)
parente23f8b095b341b43a9696562889a4db096bebb9d (diff)
downloadrust-3e56732322fdfa65e640a5bd89f6f38e45e8312d.tar.gz
rust-3e56732322fdfa65e640a5bd89f6f38e45e8312d.zip
Rollup merge of #31219 - mbrubeck:missing-docs, r=steveklabnik
The missing_docs lint only applies to public items in public modules, so this
example code did not actually generate any warnings or errors.
-rw-r--r--src/doc/reference.md8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/doc/reference.md b/src/doc/reference.md
index f0fdae27ac7..46fdee2bb5a 100644
--- a/src/doc/reference.md
+++ b/src/doc/reference.md
@@ -2095,7 +2095,7 @@ along with their default settings.  [Compiler
 plugins](book/compiler-plugins.html#lint-plugins) can provide additional lint checks.
 
 ```{.ignore}
-mod m1 {
+pub mod m1 {
     // Missing documentation is ignored here
     #[allow(missing_docs)]
     pub fn undocumented_one() -> i32 { 1 }
@@ -2115,9 +2115,9 @@ check on and off:
 
 ```{.ignore}
 #[warn(missing_docs)]
-mod m2{
+pub mod m2{
     #[allow(missing_docs)]
-    mod nested {
+    pub mod nested {
         // Missing documentation is ignored here
         pub fn undocumented_one() -> i32 { 1 }
 
@@ -2137,7 +2137,7 @@ that lint check:
 
 ```{.ignore}
 #[forbid(missing_docs)]
-mod m3 {
+pub mod m3 {
     // Attempting to toggle warning signals an error here
     #[allow(missing_docs)]
     /// Returns 2.