Skip to content

Commit 011a35d

Browse files
committed
---
yaml --- r: 100818 b: refs/heads/snap-stage3 c: f0bad90 h: refs/heads/master v: v3
1 parent 4fa7706 commit 011a35d

Some content is hidden

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

56 files changed

+494
-316
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: e3b1f3c443c048913e2d573fcc5a9c2be3484a78
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: 90311fc68fb484310df9ffc614e592dee30644ae
4+
refs/heads/snap-stage3: f0bad904a1b53c5c5972e24edd79a96a1d442576
55
refs/heads/try: a97642026c18a624ff6ea01075dd9550f8ed07ff
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b

branches/snap-stage3/mk/crates.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,9 @@ DEPS_extra := std term sync serialize getopts collections
6060
DEPS_green := std native:context_switch
6161
DEPS_rustuv := std native:uv native:uv_support
6262
DEPS_native := std
63-
DEPS_syntax := std extra term serialize collections
63+
DEPS_syntax := std term serialize collections
6464
DEPS_rustc := syntax native:rustllvm flate arena serialize sync getopts \
65-
collections
65+
collections extra
6666
DEPS_rustdoc := rustc native:sundown serialize sync getopts collections
6767
DEPS_flate := std native:miniz
6868
DEPS_arena := std collections

branches/snap-stage3/mk/rt.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ COMPRT_NAME_$(1) := $$(call CFG_STATIC_LIB_NAME_$(1),compiler-rt)
236236
COMPRT_LIB_$(1) := $$(RT_OUTPUT_DIR_$(1))/$$(COMPRT_NAME_$(1))
237237
COMPRT_BUILD_DIR_$(1) := $$(RT_OUTPUT_DIR_$(1))/compiler-rt
238238

239-
$$(COMPRT_LIB_$(1)): $$(COMPRT_DEPS)
239+
$$(COMPRT_LIB_$(1)): $$(COMPRT_DEPS) $$(MKFILE_DEPS)
240240
@$$(call E, make: compiler-rt)
241241
$$(Q)$$(MAKE) -C "$(S)src/compiler-rt" \
242242
ProjSrcRoot="$(S)src/compiler-rt" \

branches/snap-stage3/src/compiletest/header.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ pub struct TestProps {
3030
check_lines: ~[~str],
3131
// Flag to force a crate to be built with the host architecture
3232
force_host: bool,
33+
// Check stdout for error-pattern output as well as stderr
34+
check_stdout: bool,
3335
}
3436

3537
// Load any test directives embedded in the file
@@ -42,6 +44,7 @@ pub fn load_props(testfile: &Path) -> TestProps {
4244
let mut debugger_cmds = ~[];
4345
let mut check_lines = ~[];
4446
let mut force_host = false;
47+
let mut check_stdout = false;
4548
iter_header(testfile, |ln| {
4649
match parse_error_pattern(ln) {
4750
Some(ep) => error_patterns.push(ep),
@@ -60,6 +63,10 @@ pub fn load_props(testfile: &Path) -> TestProps {
6063
force_host = parse_force_host(ln);
6164
}
6265

66+
if !check_stdout {
67+
check_stdout = parse_check_stdout(ln);
68+
}
69+
6370
match parse_aux_build(ln) {
6471
Some(ab) => { aux_builds.push(ab); }
6572
None => {}
@@ -91,6 +98,7 @@ pub fn load_props(testfile: &Path) -> TestProps {
9198
debugger_cmds: debugger_cmds,
9299
check_lines: check_lines,
93100
force_host: force_host,
101+
check_stdout: check_stdout,
94102
};
95103
}
96104

@@ -155,6 +163,10 @@ fn parse_force_host(line: &str) -> bool {
155163
parse_name_directive(line, "force-host")
156164
}
157165

166+
fn parse_check_stdout(line: &str) -> bool {
167+
parse_name_directive(line, "check-stdout")
168+
}
169+
158170
fn parse_exec_env(line: &str) -> Option<(~str, ~str)> {
159171
parse_name_value_directive(line, ~"exec-env").map(|nv| {
160172
// nv is either FOO or FOO=BAR

branches/snap-stage3/src/compiletest/runtest.rs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -452,7 +452,12 @@ fn check_error_patterns(props: &TestProps,
452452
let mut next_err_idx = 0u;
453453
let mut next_err_pat = &props.error_patterns[next_err_idx];
454454
let mut done = false;
455-
for line in ProcRes.stderr.lines() {
455+
let output_to_check = if props.check_stdout {
456+
ProcRes.stdout + ProcRes.stderr
457+
} else {
458+
ProcRes.stderr.clone()
459+
};
460+
for line in output_to_check.lines() {
456461
if line.contains(*next_err_pat) {
457462
debug!("found error pattern {}", *next_err_pat);
458463
next_err_idx += 1u;

branches/snap-stage3/src/doc/tutorial.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,8 @@ they don't contain references to names that aren't actually defined.
5757
5858
# Getting started
5959

60-
> **NOTE**: The tarball and installer links are for the most recent release,
61-
> not master.
60+
> **WARNING**: The tarball and installer links are for the most recent
61+
> release, not master. To use master, you **must** build from [git].
6262
6363
The Rust compiler currently must be built from a [tarball] or [git], unless
6464
you are on Windows, in which case using the [installer][win-exe] is

branches/snap-stage3/src/etc/emacs/rust-mode.el

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,7 @@
130130
'("as"
131131
"break"
132132
"continue"
133+
"crate"
133134
"do"
134135
"else" "enum" "extern"
135136
"false" "fn" "for"

branches/snap-stage3/src/etc/gedit/share/gtksourceview-3.0/language-specs/rust.lang

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@
4040
<keyword>break</keyword>
4141
<keyword>const</keyword>
4242
<keyword>continue</keyword>
43+
<keyword>crate</keyword>
4344
<keyword>do</keyword>
4445
<keyword>drop</keyword>
4546
<keyword>else</keyword>

branches/snap-stage3/src/etc/kate/rust.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
<item> as </item>
2020
<item> break </item>
2121
<item> continue </item>
22+
<item> crate </item>
2223
<item> do </item>
2324
<item> drop </item>
2425
<item> else </item>

branches/snap-stage3/src/etc/vim/syntax/rust.vim

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
" Maintainer: Patrick Walton <[email protected]>
44
" Maintainer: Ben Blum <[email protected]>
55
" Maintainer: Chris Morgan <[email protected]>
6-
" Last Change: 2014 Jan 4
6+
" Last Change: 2014 Feb 14
77

88
if version < 600
99
syntax clear
@@ -18,7 +18,8 @@ syn keyword rustOperator as
1818

1919
syn match rustAssert "\<assert\(\w\)*!" contained
2020
syn match rustFail "\<fail\(\w\)*!" contained
21-
syn keyword rustKeyword break continue do extern
21+
syn keyword rustKeyword break continue do
22+
syn keyword rustKeyword extern nextgroup=rustExternCrate skipwhite
2223
syn keyword rustKeyword for in if impl let
2324
syn keyword rustKeyword loop once priv pub
2425
syn keyword rustKeyword return
@@ -31,6 +32,10 @@ syn keyword rustKeyword proc
3132
syn keyword rustStorage mut ref static
3233
syn keyword rustObsoleteStorage const
3334

35+
syn keyword rustInvalidBareKeyword crate
36+
37+
syn keyword rustExternCrate crate contained nextgroup=rustIdentifier skipwhite
38+
3439
syn match rustIdentifier contains=rustIdentifierPrime "\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*" display contained
3540
syn match rustFuncName "\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*" display contained
3641

@@ -81,7 +86,7 @@ syn keyword rustTrait OrdIterator MutableDoubleEndedIterator ExactSize
8186

8287
syn keyword rustTrait Algebraic Trigonometric Exponential Hyperbolic
8388
syn keyword rustTrait Bitwise Bounded Integer Fractional Real RealExt
84-
syn keyword rustTrait Num NumCast CheckedAdd CheckedSub CheckedMul
89+
syn keyword rustTrait Num NumCast CheckedAdd CheckedSub CheckedMul CheckedDiv
8590
syn keyword rustTrait Orderable Signed Unsigned Round
8691
syn keyword rustTrait Primitive Int Float ToStrRadix ToPrimitive FromPrimitive
8792
syn keyword rustTrait GenericPath Path PosixPath WindowsPath
@@ -245,6 +250,8 @@ hi def link rustDeriving PreProc
245250
hi def link rustStorage StorageClass
246251
hi def link rustObsoleteStorage Error
247252
hi def link rustLifetime Special
253+
hi def link rustInvalidBareKeyword Error
254+
hi def link rustExternCrate rustKeyword
248255

249256
" Other Suggestions:
250257
" hi rustAttribute ctermfg=cyan

branches/snap-stage3/src/libcollections/bitv.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1561,6 +1561,7 @@ mod tests {
15611561
let mut bitv = 0 as uint;
15621562
b.iter(|| {
15631563
bitv |= (1 << ((r.next_u32() as uint) % uint::BITS));
1564+
&bitv
15641565
})
15651566
}
15661567

@@ -1570,6 +1571,7 @@ mod tests {
15701571
let mut bitv = SmallBitv::new(uint::BITS);
15711572
b.iter(|| {
15721573
bitv.set((r.next_u32() as uint) % uint::BITS, true);
1574+
&bitv
15731575
})
15741576
}
15751577

@@ -1579,6 +1581,7 @@ mod tests {
15791581
let mut bitv = BigBitv::new(~[0]);
15801582
b.iter(|| {
15811583
bitv.set((r.next_u32() as uint) % uint::BITS, true);
1584+
&bitv
15821585
})
15831586
}
15841587

@@ -1590,6 +1593,7 @@ mod tests {
15901593
let mut bitv = BigBitv::new(storage);
15911594
b.iter(|| {
15921595
bitv.set((r.next_u32() as uint) % BENCH_BITS, true);
1596+
&bitv
15931597
})
15941598
}
15951599

@@ -1599,6 +1603,7 @@ mod tests {
15991603
let mut bitv = Bitv::new(BENCH_BITS, false);
16001604
b.iter(|| {
16011605
bitv.set((r.next_u32() as uint) % BENCH_BITS, true);
1606+
&bitv
16021607
})
16031608
}
16041609

@@ -1608,6 +1613,7 @@ mod tests {
16081613
let mut bitv = Bitv::new(uint::BITS, false);
16091614
b.iter(|| {
16101615
bitv.set((r.next_u32() as uint) % uint::BITS, true);
1616+
&bitv
16111617
})
16121618
}
16131619

@@ -1617,6 +1623,7 @@ mod tests {
16171623
let mut bitv = BitvSet::new();
16181624
b.iter(|| {
16191625
bitv.insert((r.next_u32() as uint) % uint::BITS);
1626+
&bitv
16201627
})
16211628
}
16221629

@@ -1626,6 +1633,7 @@ mod tests {
16261633
let mut bitv = BitvSet::new();
16271634
b.iter(|| {
16281635
bitv.insert((r.next_u32() as uint) % BENCH_BITS);
1636+
&bitv
16291637
})
16301638
}
16311639

branches/snap-stage3/src/libcollections/deque.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,8 +115,9 @@ pub mod bench {
115115
// measure
116116
let mut i = 0;
117117
bh.iter(|| {
118-
map.find(&i);
118+
let x = map.find(&i);
119119
i = (i + 1) % n;
120+
x
120121
})
121122
}
122123
}

0 commit comments

Comments
 (0)