Skip to content

Commit d9bd437

Browse files
committed
---
yaml --- r: 67218 b: refs/heads/master c: c6c1472 h: refs/heads/master v: v3
1 parent 9416412 commit d9bd437

File tree

149 files changed

+8628
-3269
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

149 files changed

+8628
-3269
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: e029c2d623957d52b5a5ad01f1d8e000e1e56555
2+
refs/heads/master: c6c1472c6845ea02fad009603b1c2331b679ed67
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 18e3db7392d2d0697b7e27d6d986139960144d85
55
refs/heads/try: 7b78b52e602bb3ea8174f9b2006bff3315f03ef9

trunk/doc/tutorial.md

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -499,8 +499,8 @@ types.
499499
> items.
500500
501501
~~~~
502-
use std::float;
503-
use std::num::atan;
502+
# use std::float;
503+
# use std::num::atan;
504504
fn angle(vector: (float, float)) -> float {
505505
let pi = float::consts::pi;
506506
match vector {
@@ -555,7 +555,7 @@ while cake_amount > 0 {
555555
`loop` denotes an infinite loop, and is the preferred way of writing `while true`:
556556

557557
~~~~
558-
use std::int;
558+
# use std::int;
559559
let mut x = 5;
560560
loop {
561561
x += x - 3;
@@ -701,7 +701,7 @@ get at their contents. All variant constructors can be used as
701701
patterns, as in this definition of `area`:
702702

703703
~~~~
704-
use std::float;
704+
# use std::float;
705705
# struct Point {x: float, y: float}
706706
# enum Shape { Circle(Point, float), Rectangle(Point, Point) }
707707
fn area(sh: Shape) -> float {
@@ -733,7 +733,7 @@ fn point_from_direction(dir: Direction) -> Point {
733733
Enum variants may also be structs. For example:
734734

735735
~~~~
736-
use std::float;
736+
# use std::float;
737737
# struct Point { x: float, y: float }
738738
# fn square(x: float) -> float { x * x }
739739
enum Shape {
@@ -1599,8 +1599,7 @@ lists back to back. Since that is so unsightly, empty argument lists
15991599
may be omitted from `do` expressions.
16001600

16011601
~~~~
1602-
use std::task::spawn;
1603-
1602+
# use std::task::spawn;
16041603
do spawn {
16051604
debug!("Kablam!");
16061605
}
@@ -1729,7 +1728,7 @@ impl Circle {
17291728
To call such a method, just prefix it with the type name and a double colon:
17301729

17311730
~~~~
1732-
use std::float::consts::pi;
1731+
# use std::float::consts::pi;
17331732
struct Circle { radius: float }
17341733
impl Circle {
17351734
fn new(area: float) -> Circle { Circle { radius: (area / pi).sqrt() } }
@@ -1775,7 +1774,7 @@ illegal to copy and pass by value.
17751774
Generic `type`, `struct`, and `enum` declarations follow the same pattern:
17761775

17771776
~~~~
1778-
use std::hashmap::HashMap;
1777+
# use std::hashmap::HashMap;
17791778
type Set<T> = HashMap<T, ()>;
17801779
17811780
struct Stack<T> {
@@ -2001,7 +2000,7 @@ name and a double colon. The compiler uses type inference to decide which
20012000
implementation to use.
20022001

20032002
~~~~
2004-
use std::float::consts::pi;
2003+
# use std::float::consts::pi;
20052004
trait Shape { fn new(area: float) -> Self; }
20062005
struct Circle { radius: float }
20072006
struct Square { length: float }
@@ -2157,7 +2156,7 @@ trait Circle : Shape { fn radius(&self) -> float; }
21572156
Now, we can implement `Circle` on a type only if we also implement `Shape`.
21582157

21592158
~~~~
2160-
use std::float::consts::pi;
2159+
# use std::float::consts::pi;
21612160
# trait Shape { fn area(&self) -> float; }
21622161
# trait Circle : Shape { fn radius(&self) -> float; }
21632162
# struct Point { x: float, y: float }
@@ -2192,7 +2191,7 @@ fn radius_times_area<T: Circle>(c: T) -> float {
21922191
Likewise, supertrait methods may also be called on trait objects.
21932192

21942193
~~~ {.xfail-test}
2195-
use std::float::consts::pi;
2194+
# use std::float::consts::pi;
21962195
# trait Shape { fn area(&self) -> float; }
21972196
# trait Circle : Shape { fn radius(&self) -> float; }
21982197
# struct Point { x: float, y: float }

trunk/mk/target.mk

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ export CFG_COMPILER_TRIPLE
1717
# code, make sure that these common warnings are denied by default. These can
1818
# be overridden during development temporarily. For stage0, we allow all these
1919
# to suppress warnings which may be bugs in stage0 (should be fixed in stage1+)
20-
WFLAGS_ST0 = -A warnings
20+
# NOTE: add "-A warnings" after snapshot to WFLAGS_ST0
21+
WFLAGS_ST0 = -A unrecognized-lint
2122
WFLAGS_ST1 = -D warnings
2223
WFLAGS_ST2 = -D warnings
2324

trunk/src/compiletest/compiletest.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -242,13 +242,13 @@ pub fn make_tests(config: &config) -> ~[test::TestDescAndFn] {
242242
let mut tests = ~[];
243243
let dirs = os::list_dir_path(&config.src_base);
244244
for dirs.iter().advance |file| {
245-
let file = file.clone();
245+
let file = (*file).clone();
246246
debug!("inspecting file %s", file.to_str());
247-
if is_test(config, &file) {
248-
let t = do make_test(config, &file) {
247+
if is_test(config, file) {
248+
let t = do make_test(config, file) {
249249
match config.mode {
250-
mode_codegen => make_metrics_test_closure(config, &file),
251-
_ => make_test_closure(config, &file)
250+
mode_codegen => make_metrics_test_closure(config, file),
251+
_ => make_test_closure(config, file)
252252
}
253253
};
254254
tests.push(t)

0 commit comments

Comments
 (0)