Skip to content

Commit 379a4e2

Browse files
committed
---
yaml --- r: 120603 b: refs/heads/dist-snap c: 33573bc h: refs/heads/master i: 120601: a820dd6 120599: ebe30b3 v: v3
1 parent cedcdbc commit 379a4e2

File tree

15 files changed

+62
-285
lines changed

15 files changed

+62
-285
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ refs/heads/try: 1813e5aa1a03b0596b8de7abd1af31edf5d6098f
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c
9-
refs/heads/dist-snap: 0dd4c1e7bd0178ca91ea13dfad6efc4cce728302
9+
refs/heads/dist-snap: 33573bc0aaec14c55adbe6be314f761f34f8cdd0
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
1212
refs/heads/try3: 9387340aab40a73e8424c48fd42f0c521a4875c0

branches/dist-snap/src/librustc/middle/privacy.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1094,7 +1094,10 @@ impl<'a> SanePrivacyVisitor<'a> {
10941094
check_inherited(m.span, m.vis,
10951095
"unnecessary visibility");
10961096
}
1097-
ast::Required(..) => {}
1097+
ast::Required(ref m) => {
1098+
check_inherited(m.span, m.vis,
1099+
"unnecessary visibility");
1100+
}
10981101
}
10991102
}
11001103
}

branches/dist-snap/src/librustdoc/html/highlight.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ fn doit(sess: &parse::ParseSess, mut lexer: lexer::StringReader, class: Option<&
102102

103103
// miscellaneous, no highlighting
104104
t::DOT | t::DOTDOT | t::DOTDOTDOT | t::COMMA | t::SEMI |
105-
t::COLON | t::MOD_SEP | t::LARROW | t::DARROW | t::LPAREN |
105+
t::COLON | t::MOD_SEP | t::LARROW | t::LPAREN |
106106
t::RPAREN | t::LBRACKET | t::LBRACE | t::RBRACE => "",
107107
t::DOLLAR => {
108108
if t::is_ident(&lexer.peek().tok) {

branches/dist-snap/src/libsyntax/ast.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -689,6 +689,7 @@ pub struct TypeMethod {
689689
pub explicit_self: ExplicitSelf,
690690
pub id: NodeId,
691691
pub span: Span,
692+
pub vis: Visibility,
692693
}
693694

694695
// A trait method is either required (meaning it doesn't have an

branches/dist-snap/src/libsyntax/ast_util.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -305,6 +305,7 @@ pub fn trait_method_to_ty_method(method: &TraitMethod) -> TypeMethod {
305305
explicit_self: m.explicit_self,
306306
id: m.id,
307307
span: m.span,
308+
vis: m.vis,
308309
}
309310
}
310311
}

branches/dist-snap/src/libsyntax/ext/quote.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -543,7 +543,6 @@ fn mk_token(cx: &ExtCtxt, sp: Span, tok: &token::Token) -> @ast::Expr {
543543
MOD_SEP => "MOD_SEP",
544544
RARROW => "RARROW",
545545
LARROW => "LARROW",
546-
DARROW => "DARROW",
547546
FAT_ARROW => "FAT_ARROW",
548547
LPAREN => "LPAREN",
549548
RPAREN => "RPAREN",

branches/dist-snap/src/libsyntax/fold.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -648,6 +648,7 @@ pub fn noop_fold_type_method<T: Folder>(m: &TypeMethod, fld: &mut T) -> TypeMeth
648648
generics: fold_generics(&m.generics, fld),
649649
explicit_self: fld.fold_explicit_self(&m.explicit_self),
650650
span: fld.new_span(m.span),
651+
vis: m.vis,
651652
}
652653
}
653654

branches/dist-snap/src/libsyntax/parse/lexer.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -790,10 +790,7 @@ fn next_token_inner(rdr: &mut StringReader) -> token::Token {
790790
'<' => { return binop(rdr, token::SHL); }
791791
'-' => {
792792
bump(rdr);
793-
match rdr.curr.unwrap_or('\x00') {
794-
'>' => { bump(rdr); return token::DARROW; }
795-
_ => { return token::LARROW; }
796-
}
793+
return token::LARROW;
797794
}
798795
_ => { return token::LT; }
799796
}

branches/dist-snap/src/libsyntax/parse/obsolete.rs

Lines changed: 0 additions & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -25,21 +25,6 @@ use parse::token;
2525
/// The specific types of unsupported syntax
2626
#[deriving(Eq, TotalEq, Hash)]
2727
pub enum ObsoleteSyntax {
28-
ObsoleteSwap,
29-
ObsoleteUnsafeBlock,
30-
ObsoleteBareFnType,
31-
ObsoleteMultipleLocalDecl,
32-
ObsoleteUnsafeExternFn,
33-
ObsoleteTraitFuncVisibility,
34-
ObsoleteConstPointer,
35-
ObsoleteLoopAsContinue,
36-
ObsoleteEnumWildcard,
37-
ObsoleteStructWildcard,
38-
ObsoleteVecDotDotWildcard,
39-
ObsoleteMultipleImport,
40-
ObsoleteManagedPattern,
41-
ObsoleteManagedString,
42-
ObsoleteManagedVec,
4328
ObsoleteOwnedType,
4429
ObsoleteOwnedExpr,
4530
ObsoleteOwnedPattern,
@@ -64,71 +49,6 @@ impl<'a> ParserObsoleteMethods for Parser<'a> {
6449
/// Reports an obsolete syntax non-fatal error.
6550
fn obsolete(&mut self, sp: Span, kind: ObsoleteSyntax) {
6651
let (kind_str, desc) = match kind {
67-
ObsoleteSwap => (
68-
"swap",
69-
"use std::mem::{swap, replace} instead"
70-
),
71-
ObsoleteUnsafeBlock => (
72-
"non-standalone unsafe block",
73-
"use an inner `unsafe { ... }` block instead"
74-
),
75-
ObsoleteBareFnType => (
76-
"bare function type",
77-
"use `|A| -> B` or `extern fn(A) -> B` instead"
78-
),
79-
ObsoleteMultipleLocalDecl => (
80-
"declaration of multiple locals at once",
81-
"instead of e.g. `let a = 1, b = 2`, write \
82-
`let (a, b) = (1, 2)`."
83-
),
84-
ObsoleteUnsafeExternFn => (
85-
"unsafe external function",
86-
"external functions are always unsafe; remove the `unsafe` \
87-
keyword"
88-
),
89-
ObsoleteTraitFuncVisibility => (
90-
"visibility not necessary",
91-
"trait functions inherit the visibility of the trait itself"
92-
),
93-
ObsoleteConstPointer => (
94-
"const pointer",
95-
"instead of `&const Foo` or `@const Foo`, write `&Foo` or \
96-
`@Foo`"
97-
),
98-
ObsoleteLoopAsContinue => (
99-
"`loop` instead of `continue`",
100-
"`loop` is now only used for loops and `continue` is used for \
101-
skipping iterations"
102-
),
103-
ObsoleteEnumWildcard => (
104-
"enum wildcard",
105-
"use `..` instead of `*` for matching all enum fields"
106-
),
107-
ObsoleteStructWildcard => (
108-
"struct wildcard",
109-
"use `..` instead of `_` for matching trailing struct fields"
110-
),
111-
ObsoleteVecDotDotWildcard => (
112-
"vec slice wildcard",
113-
"use `..` instead of `.._` for matching slices"
114-
),
115-
ObsoleteMultipleImport => (
116-
"multiple imports",
117-
"only one import is allowed per `use` statement"
118-
),
119-
ObsoleteManagedPattern => (
120-
"managed pointer pattern",
121-
"use a nested `match` expression instead of a managed box \
122-
pattern"
123-
),
124-
ObsoleteManagedString => (
125-
"managed string",
126-
"use `Rc<StrBuf>` instead of a managed string"
127-
),
128-
ObsoleteManagedVec => (
129-
"managed vector",
130-
"use `Rc<~[T]>` instead of a managed vector"
131-
),
13252
ObsoleteOwnedType => (
13353
"`~` notation for owned pointers",
13454
"use `Box<T>` in `std::owned` instead"

0 commit comments

Comments
 (0)