Skip to content

Commit e6968f7

Browse files
---
yaml --- r: 157422 b: refs/heads/snap-stage3 c: 47e8cf7 h: refs/heads/master v: v3
1 parent 4c714fe commit e6968f7

File tree

90 files changed

+110
-122
lines changed

Some content is hidden

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

90 files changed

+110
-122
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: 065caf34f5ff29e04605f95d9c5d511af219439a
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: 9f0c29af0263a13c123722122877f818dfec3b8f
4+
refs/heads/snap-stage3: 47e8cf76977d7a46ea2aed512c35b175e44815a9
55
refs/heads/try: 0ee4d8b0b112c608646fa75463ab4dc59132efd9
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4326,7 +4326,7 @@ The most common consumer is `collect()`. This code doesn't quite compile,
43264326
but it shows the intention:
43274327

43284328
```{rust,ignore}
4329-
let one_to_one_hundred = range(1i, 101i).collect();
4329+
let one_to_one_hundred = range(0i, 100i).collect();
43304330
```
43314331

43324332
As you can see, we call `collect()` on our iterator. `collect()` takes
@@ -4336,7 +4336,7 @@ type of things you want to collect, and so you need to let it know.
43364336
Here's the version that does compile:
43374337

43384338
```{rust}
4339-
let one_to_one_hundred = range(1i, 101i).collect::<Vec<int>>();
4339+
let one_to_one_hundred = range(0i, 100i).collect::<Vec<int>>();
43404340
```
43414341

43424342
If you remember, the `::<>` syntax allows us to give a type hint,

branches/snap-stage3/src/librustc/middle/traits/coherence.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,9 +67,9 @@ pub fn impl_is_local(tcx: &ty::ctxt,
6767
return true;
6868
}
6969

70-
// Otherwise, at least one of the input types must be local to the
71-
// crate.
72-
trait_ref.input_types().iter().any(|&t| ty_is_local(tcx, t))
70+
// Otherwise, self type must be local to the crate.
71+
let self_ty = ty::lookup_item_type(tcx, impl_def_id).ty;
72+
return ty_is_local(tcx, self_ty);
7373
}
7474

7575
pub fn ty_is_local(tcx: &ty::ctxt,

branches/snap-stage3/src/librustdoc/passes.rs

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -134,18 +134,7 @@ impl<'a> fold::DocFolder for Stripper<'a> {
134134
clean::StructItem(..) | clean::EnumItem(..) |
135135
clean::TraitItem(..) | clean::FunctionItem(..) |
136136
clean::VariantItem(..) | clean::MethodItem(..) |
137-
clean::ForeignFunctionItem(..) | clean::ForeignStaticItem(..) => {
138-
if ast_util::is_local(i.def_id) {
139-
if !self.exported_items.contains(&i.def_id.node) {
140-
return None;
141-
}
142-
// Traits are in exported_items even when they're totally private.
143-
if i.is_trait() && i.visibility != Some(ast::Public) {
144-
return None;
145-
}
146-
}
147-
}
148-
137+
clean::ForeignFunctionItem(..) | clean::ForeignStaticItem(..) |
149138
clean::ConstantItem(..) => {
150139
if ast_util::is_local(i.def_id) &&
151140
!self.exported_items.contains(&i.def_id.node) {

branches/snap-stage3/src/libsyntax/parse/mod.rs

Lines changed: 1 addition & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -721,7 +721,7 @@ pub fn integer_lit(s: &str, sd: &SpanHandler, sp: Span) -> ast::Lit_ {
721721
mod test {
722722
use super::*;
723723
use serialize::json;
724-
use codemap::{Span, BytePos, Pos, Spanned, NO_EXPANSION};
724+
use codemap::{Span, BytePos, Spanned, NO_EXPANSION};
725725
use owned_slice::OwnedSlice;
726726
use ast;
727727
use abi;
@@ -1121,46 +1121,6 @@ mod test {
11211121
span: sp(0,21)})));
11221122
}
11231123

1124-
fn get_spans_of_pat_idents(src: &str) -> Vec<Span> {
1125-
let item = string_to_item(src.to_string()).unwrap();
1126-
1127-
struct PatIdentVisitor {
1128-
spans: Vec<Span>
1129-
}
1130-
impl<'v> ::visit::Visitor<'v> for PatIdentVisitor {
1131-
fn visit_pat(&mut self, p: &'v ast::Pat) {
1132-
match p.node {
1133-
ast::PatIdent(_ , ref spannedident, _) => {
1134-
self.spans.push(spannedident.span.clone());
1135-
}
1136-
_ => {
1137-
::visit::walk_pat(self, p);
1138-
}
1139-
}
1140-
}
1141-
}
1142-
let mut v = PatIdentVisitor { spans: Vec::new() };
1143-
::visit::walk_item(&mut v, &*item);
1144-
return v.spans;
1145-
}
1146-
1147-
#[test] fn span_of_self_arg_pat_idents_are_correct() {
1148-
1149-
let srcs = ["impl z { fn a (&self, &myarg: int) {} }",
1150-
"impl z { fn a (&mut self, &myarg: int) {} }",
1151-
"impl z { fn a (&'a self, &myarg: int) {} }",
1152-
"impl z { fn a (self, &myarg: int) {} }",
1153-
"impl z { fn a (self: Foo, &myarg: int) {} }",
1154-
];
1155-
1156-
for &src in srcs.iter() {
1157-
let spans = get_spans_of_pat_idents(src);
1158-
let Span{lo:lo,hi:hi,..} = spans[0];
1159-
assert!("self" == src.slice(lo.to_uint(), hi.to_uint()),
1160-
"\"{}\" != \"self\". src=\"{}\"",
1161-
src.slice(lo.to_uint(), hi.to_uint()), src)
1162-
}
1163-
}
11641124

11651125
#[test] fn parse_exprs () {
11661126
// just make sure that they parse....

branches/snap-stage3/src/libsyntax/parse/parser.rs

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4165,16 +4165,10 @@ impl<'a> Parser<'a> {
41654165
// A bit of complexity and lookahead is needed here in order to be
41664166
// backwards compatible.
41674167
let lo = self.span.lo;
4168-
let mut self_ident_lo = self.span.lo;
4169-
let mut self_ident_hi = self.span.hi;
4170-
41714168
let mut mutbl_self = MutImmutable;
41724169
let explicit_self = match self.token {
41734170
token::BINOP(token::AND) => {
4174-
let eself = maybe_parse_borrowed_explicit_self(self);
4175-
self_ident_lo = self.last_span.lo;
4176-
self_ident_hi = self.last_span.hi;
4177-
eself
4171+
maybe_parse_borrowed_explicit_self(self)
41784172
}
41794173
token::TILDE => {
41804174
// We need to make sure it isn't a type
@@ -4246,7 +4240,7 @@ impl<'a> Parser<'a> {
42464240
_ => SelfStatic,
42474241
};
42484242

4249-
let explicit_self_sp = mk_sp(self_ident_lo, self_ident_hi);
4243+
let explicit_self_sp = mk_sp(lo, self.span.hi);
42504244

42514245
// shared fall-through for the three cases below. borrowing prevents simply
42524246
// writing this as a closure

branches/snap-stage3/src/test/auxiliary/coherence-orphan-lib.rs

Lines changed: 0 additions & 14 deletions
This file was deleted.

branches/snap-stage3/src/test/compile-fail/coherence-orphan.rs

Lines changed: 0 additions & 25 deletions
This file was deleted.

branches/snap-stage3/src/test/debuginfo/basic-types-globals-metadata.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010

1111
// ignore-windows: FIXME #13256
1212
// ignore-android: FIXME(#10381)
13+
// min-lldb-version: 310
1314

1415
// compile-flags:-g
1516
// gdb-command:rbreak zzz

branches/snap-stage3/src/test/debuginfo/basic-types-globals.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616

1717
// ignore-windows: FIXME #13256
1818
// ignore-android: FIXME(#10381)
19+
// min-lldb-version: 310
1920

2021
// compile-flags:-g
2122
// gdb-command:rbreak zzz

branches/snap-stage3/src/test/debuginfo/basic-types-metadata.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12+
// min-lldb-version: 310
1213

1314
// compile-flags:-g
1415
// gdb-command:rbreak zzz

branches/snap-stage3/src/test/debuginfo/basic-types-mut-globals.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616

1717
// ignore-windows: FIXME #13256
1818
// ignore-android: FIXME(#10381)
19+
// min-lldb-version: 310
1920

2021
// compile-flags:-g
2122
// gdb-command:rbreak zzz

branches/snap-stage3/src/test/debuginfo/basic-types.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
// its numerical value.
1616

1717
// ignore-android: FIXME(#10381)
18+
// min-lldb-version: 310
1819

1920
// compile-flags:-g
2021

branches/snap-stage3/src/test/debuginfo/borrowed-basic.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// its numerical value.
1515

1616
// compile-flags:-g
17+
// min-lldb-version: 310
1718

1819
// === GDB TESTS ===================================================================================
1920

branches/snap-stage3/src/test/debuginfo/borrowed-c-style-enum.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
// ignore-android: FIXME(#10381)
1212

1313
// compile-flags:-g
14+
// min-lldb-version: 310
1415

1516
// === GDB TESTS ===================================================================================
1617

branches/snap-stage3/src/test/debuginfo/borrowed-enum.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010

1111
// ignore-tidy-linelength
1212
// ignore-android: FIXME(#10381)
13+
// min-lldb-version: 310
1314

1415
// compile-flags:-g
1516

branches/snap-stage3/src/test/debuginfo/borrowed-struct.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010

1111
// ignore-android: FIXME(#10381)
1212
// compile-flags:-g
13+
// min-lldb-version: 310
1314

1415
// === GDB TESTS ===================================================================================
1516

branches/snap-stage3/src/test/debuginfo/borrowed-tuple.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12-
12+
// min-lldb-version: 310
1313

1414
// compile-flags:-g
1515

branches/snap-stage3/src/test/debuginfo/borrowed-unique-basic.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12+
// min-lldb-version: 310
1213

1314
// Gdb doesn't know about UTF-32 character encoding and will print a rust char as only
1415
// its numerical value.

branches/snap-stage3/src/test/debuginfo/box.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12+
// min-lldb-version: 310
1213

1314
// compile-flags:-g
1415

branches/snap-stage3/src/test/debuginfo/boxed-struct.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12+
// min-lldb-version: 310
1213

1314
// compile-flags:-g
1415

branches/snap-stage3/src/test/debuginfo/by-value-non-immediate-argument.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010

1111
// ignore-tidy-linelength
1212
// ignore-android: FIXME(#10381)
13+
// min-lldb-version: 310
1314

1415
// compile-flags:-g
1516

branches/snap-stage3/src/test/debuginfo/by-value-self-argument-in-trait-impl.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12-
12+
// min-lldb-version: 310
1313

1414
// compile-flags:-g
1515

branches/snap-stage3/src/test/debuginfo/c-style-enum-in-composite.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010

1111
// ignore-tidy-linelength
1212
// ignore-android: FIXME(#10381)
13+
// min-lldb-version: 310
1314

1415
// compile-flags:-g
1516

branches/snap-stage3/src/test/debuginfo/c-style-enum.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010

1111
// ignore-windows: FIXME #13256
1212
// ignore-android: FIXME(#10381)
13+
// min-lldb-version: 310
1314

1415
// compile-flags:-g
1516

branches/snap-stage3/src/test/debuginfo/closure-in-generic-function.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12+
// min-lldb-version: 310
1213

1314
// compile-flags:-g
1415

branches/snap-stage3/src/test/debuginfo/cross-crate-type-uniquing.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12+
// min-lldb-version: 310
1213

1314
// aux-build:cross_crate_debuginfo_type_uniquing.rs
1415
extern crate cross_crate_debuginfo_type_uniquing;

branches/snap-stage3/src/test/debuginfo/destructured-fn-argument.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12+
// min-lldb-version: 310
1213

1314
// compile-flags:-g
1415

branches/snap-stage3/src/test/debuginfo/destructured-local.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12+
// min-lldb-version: 310
1213

1314
// compile-flags:-g
1415

branches/snap-stage3/src/test/debuginfo/evec-in-struct.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12+
// min-lldb-version: 310
1213

1314
// compile-flags:-g
1415

branches/snap-stage3/src/test/debuginfo/function-arg-initialization.rs

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
// except according to those terms.
1010

1111
// ignore-android: FIXME(#10381)
12+
// min-lldb-version: 310
1213

1314
// This test case checks if function arguments already have the correct value when breaking at the
1415
// first line of the function, that is if the function prologue has already been executed at the
@@ -18,17 +19,17 @@
1819

1920
// compile-flags:-g
2021
// gdb-command:set print pretty off
21-
// gdb-command:break function-arg-initialization.rs:243
22-
// gdb-command:break function-arg-initialization.rs:258
23-
// gdb-command:break function-arg-initialization.rs:262
24-
// gdb-command:break function-arg-initialization.rs:266
25-
// gdb-command:break function-arg-initialization.rs:270
26-
// gdb-command:break function-arg-initialization.rs:274
27-
// gdb-command:break function-arg-initialization.rs:278
28-
// gdb-command:break function-arg-initialization.rs:282
29-
// gdb-command:break function-arg-initialization.rs:286
30-
// gdb-command:break function-arg-initialization.rs:294
31-
// gdb-command:break function-arg-initialization.rs:301
22+
// gdb-command:break function-arg-initialization.rs:244
23+
// gdb-command:break function-arg-initialization.rs:259
24+
// gdb-command:break function-arg-initialization.rs:263
25+
// gdb-command:break function-arg-initialization.rs:267
26+
// gdb-command:break function-arg-initialization.rs:271
27+
// gdb-command:break function-arg-initialization.rs:275
28+
// gdb-command:break function-arg-initialization.rs:279
29+
// gdb-command:break function-arg-initialization.rs:283
30+
// gdb-command:break function-arg-initialization.rs:287
31+
// gdb-command:break function-arg-initialization.rs:295
32+
// gdb-command:break function-arg-initialization.rs:302
3233

3334
// === GDB TESTS ===================================================================================
3435

0 commit comments

Comments
 (0)