File tree Expand file tree Collapse file tree 1 file changed +2
-8
lines changed Expand file tree Collapse file tree 1 file changed +2
-8
lines changed Original file line number Diff line number Diff line change @@ -162,12 +162,7 @@ and functions defined in it. If it has a `main` function, it can be
162
162
compiled to an executable. Rust does not allow code that's not a
163
163
declaration to appear at the top level of the file—all statements must
164
164
live inside a function. Rust programs can also be compiled as
165
- libraries, and included in other programs. The ` extern mod std `
166
- directive that appears at the top of many examples imports the
167
- [ standard library] [ std ] , described in more detail [ later
168
- on] ( #modules-and-crates ) .
169
-
170
- [ std ] : http://doc.rust-lang.org/doc/std
165
+ libraries, and included in other programs.
171
166
172
167
## Editing Rust code
173
168
@@ -1586,8 +1581,7 @@ This code creates a closure that adds a given string to its argument,
1586
1581
returns it from a function, and then calls it:
1587
1582
1588
1583
~~~~
1589
- extern mod std;
1590
-
1584
+ # extern mod std;
1591
1585
fn mk_appender(suffix: ~str) -> fn@(~str) -> ~str {
1592
1586
return fn@(s: ~str) -> ~str { s + suffix };
1593
1587
}
You can’t perform that action at this time.
0 commit comments