about summary refs log tree commit diff
path: root/src/doc/reference.md
diff options
context:
space:
mode:
authorNick Cameron <ncameron@mozilla.com>2015-03-16 09:00:41 +1300
committerNick Cameron <ncameron@mozilla.com>2015-03-16 11:03:54 +1300
commit432011d1437ce046c25dde8a4db67dac63c19ed0 (patch)
treea58820426c5f3e925c3cdb0d11faf4d408ee37c4 /src/doc/reference.md
parent170ccd615f976fc9e90a8f14ce6c373bfdf01533 (diff)
downloadrust-432011d1437ce046c25dde8a4db67dac63c19ed0.tar.gz
rust-432011d1437ce046c25dde8a4db67dac63c19ed0.zip
Fallout in testing.
Diffstat (limited to 'src/doc/reference.md')
-rw-r--r--src/doc/reference.md8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/doc/reference.md b/src/doc/reference.md
index c4c122463a7..3fae49bfc6d 100644
--- a/src/doc/reference.md
+++ b/src/doc/reference.md
@@ -1961,16 +1961,18 @@ module through the rules above. It essentially allows public access into the
 re-exported item. For example, this program is valid:
 
 ```
-pub use self::implementation as api;
+pub use self::implementation::api;
 
 mod implementation {
-    pub fn f() {}
+    pub mod api {
+        pub fn f() {}
+    }
 }
 
 # fn main() {}
 ```
 
-This means that any external crate referencing `implementation::f` would
+This means that any external crate referencing `implementation::api::f` would
 receive a privacy violation, while the path `api::f` would be allowed.
 
 When re-exporting a private item, it can be thought of as allowing the "privacy