diff options
| author | bors <bors@rust-lang.org> | 2014-02-11 03:26:42 -0800 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-02-11 03:26:42 -0800 |
| commit | fd4979ad0427aca01e500d0d26350525e9e17f2d (patch) | |
| tree | 7c8d261f46ef2ca4bddd2482fb0d41eb19950b9f /src/doc/tutorial.md | |
| parent | 1dc6359a0abd414ed2414da2cfd3751f364a59bf (diff) | |
| parent | d2d1129ad071653e32709706bb16606506ca227a (diff) | |
auto merge of #12154 : pnkfelix/rust/fsk-factor-bigint-and-rat-out-of-libextra, r=alexcrichton
Removed use of globs present in earlier versions of modules. Fix tutorial.md to reflect `extra::rational` ==> `num::rational`.
Diffstat (limited to 'src/doc/tutorial.md')
| -rw-r--r-- | src/doc/tutorial.md | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/doc/tutorial.md b/src/doc/tutorial.md index 73fec54fbcb..f94aa5b9104 100644 --- a/src/doc/tutorial.md +++ b/src/doc/tutorial.md @@ -3026,12 +3026,12 @@ In Rust terminology, we need a way to refer to other crates. For that, Rust offers you the `extern mod` declaration: ~~~ -extern mod extra; -// extra ships with Rust, you'll find more details further down. +extern mod num; +// `num` ships with Rust (much like `extra`; more details further down). fn main() { // The rational number '1/2': - let one_half = ::extra::rational::Ratio::new(1, 2); + let one_half = ::num::rational::Ratio::new(1, 2); } ~~~ @@ -3056,10 +3056,10 @@ of both `use` and local declarations. Which can result in something like this: ~~~ -extern mod extra; +extern mod num; use farm::dog; -use extra::rational::Ratio; +use num::rational::Ratio; mod farm { pub fn dog() { println!("woof"); } @@ -3224,9 +3224,9 @@ See the [API documentation][stddoc] for details. ## The extra library -Rust also ships with the [extra library], an accumulation of useful things, +Rust ships with crates such as the [extra library], an accumulation of useful things, that are however not important enough to deserve a place in the standard -library. You can use them by linking to `extra` with an `extern mod extra;`. +library. You can link to a library such as `extra` with an `extern mod extra;`. [extra library]: extra/index.html |
