Skip to content

Commit 86f7dcc

Browse files
---
yaml --- r: 178934 b: refs/heads/tmp c: 6519d71a26f322c5af31e548c71d9ad461c17e02 h: refs/heads/master v: v3
1 parent 5721dc2 commit 86f7dcc

File tree

4 files changed

+22
-22
lines changed

4 files changed

+22
-22
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,4 @@ refs/heads/building: 126db549b038c84269a1e4fe46f051b2c15d6970
3434
refs/heads/beta: 44a287e6eb22ec3c2a687fc156813577464017f7
3535
refs/heads/windistfix: 7608dbad651f02e837ed05eef3d74a6662a6e928
3636
refs/tags/1.0.0-alpha: e42bd6d93a1d3433c486200587f8f9e12590a4d7
37-
refs/heads/tmp: 891f45426cb2952a2d32c86fa28242f82b5a7c20
37+
refs/heads/tmp: 6519d71a26f322c5af31e548c71d9ad461c17e02

branches/tmp/src/librustdoc/clean/mod.rs

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -411,12 +411,12 @@ pub enum Attribute {
411411
impl Clean<Attribute> for ast::MetaItem {
412412
fn clean(&self, cx: &DocContext) -> Attribute {
413413
match self.node {
414-
ast::MetaWord(ref s) => Word(s.get().to_string()),
414+
ast::MetaWord(ref s) => Word(s.to_string()),
415415
ast::MetaList(ref s, ref l) => {
416-
List(s.get().to_string(), l.clean(cx))
416+
List(s.to_string(), l.clean(cx))
417417
}
418418
ast::MetaNameValue(ref s, ref v) => {
419-
NameValue(s.get().to_string(), lit_to_string(v))
419+
NameValue(s.to_string(), lit_to_string(v))
420420
}
421421
}
422422
}
@@ -701,19 +701,19 @@ impl Lifetime {
701701

702702
impl Clean<Lifetime> for ast::Lifetime {
703703
fn clean(&self, _: &DocContext) -> Lifetime {
704-
Lifetime(token::get_name(self.name).get().to_string())
704+
Lifetime(token::get_name(self.name).to_string())
705705
}
706706
}
707707

708708
impl Clean<Lifetime> for ast::LifetimeDef {
709709
fn clean(&self, _: &DocContext) -> Lifetime {
710-
Lifetime(token::get_name(self.lifetime.name).get().to_string())
710+
Lifetime(token::get_name(self.lifetime.name).to_string())
711711
}
712712
}
713713

714714
impl Clean<Lifetime> for ty::RegionParameterDef {
715715
fn clean(&self, _: &DocContext) -> Lifetime {
716-
Lifetime(token::get_name(self.name).get().to_string())
716+
Lifetime(token::get_name(self.name).to_string())
717717
}
718718
}
719719

@@ -722,7 +722,7 @@ impl Clean<Option<Lifetime>> for ty::Region {
722722
match *self {
723723
ty::ReStatic => Some(Lifetime::statik()),
724724
ty::ReLateBound(_, ty::BrNamed(_, name)) =>
725-
Some(Lifetime(token::get_name(name).get().to_string())),
725+
Some(Lifetime(token::get_name(name).to_string())),
726726
ty::ReEarlyBound(_, _, _, name) => Some(Lifetime(name.clean(cx))),
727727

728728
ty::ReLateBound(..) |
@@ -1954,20 +1954,20 @@ fn path_to_string(p: &ast::Path) -> String {
19541954
} else {
19551955
first = false;
19561956
}
1957-
s.push_str(i.get());
1957+
s.push_str(&i);
19581958
}
19591959
s
19601960
}
19611961

19621962
impl Clean<String> for ast::Ident {
19631963
fn clean(&self, _: &DocContext) -> String {
1964-
token::get_ident(*self).get().to_string()
1964+
token::get_ident(*self).to_string()
19651965
}
19661966
}
19671967

19681968
impl Clean<String> for ast::Name {
19691969
fn clean(&self, _: &DocContext) -> String {
1970-
token::get_name(*self).get().to_string()
1970+
token::get_name(*self).to_string()
19711971
}
19721972
}
19731973

@@ -2159,7 +2159,7 @@ impl Clean<Vec<Item>> for doctree::Import {
21592159
// forcefully don't inline if this is not public or if the
21602160
// #[doc(no_inline)] attribute is present.
21612161
let denied = self.vis != ast::Public || self.attrs.iter().any(|a| {
2162-
a.name().get() == "doc" && match a.meta_item_list() {
2162+
&a.name()[] == "doc" && match a.meta_item_list() {
21632163
Some(l) => attr::contains_name(l, "no_inline"),
21642164
None => false,
21652165
}
@@ -2312,7 +2312,7 @@ impl ToSource for syntax::codemap::Span {
23122312

23132313
fn lit_to_string(lit: &ast::Lit) -> String {
23142314
match lit.node {
2315-
ast::LitStr(ref st, _) => st.get().to_string(),
2315+
ast::LitStr(ref st, _) => st.to_string(),
23162316
ast::LitBinary(ref data) => format!("{:?}", data),
23172317
ast::LitByte(b) => {
23182318
let mut res = String::from_str("b'");
@@ -2324,8 +2324,8 @@ fn lit_to_string(lit: &ast::Lit) -> String {
23242324
},
23252325
ast::LitChar(c) => format!("'{}'", c),
23262326
ast::LitInt(i, _t) => i.to_string(),
2327-
ast::LitFloat(ref f, _t) => f.get().to_string(),
2328-
ast::LitFloatUnsuffixed(ref f) => f.get().to_string(),
2327+
ast::LitFloat(ref f, _t) => f.to_string(),
2328+
ast::LitFloatUnsuffixed(ref f) => f.to_string(),
23292329
ast::LitBool(b) => b.to_string(),
23302330
}
23312331
}
@@ -2337,7 +2337,7 @@ fn name_from_pat(p: &ast::Pat) -> String {
23372337
match p.node {
23382338
PatWild(PatWildSingle) => "_".to_string(),
23392339
PatWild(PatWildMulti) => "..".to_string(),
2340-
PatIdent(_, ref p, _) => token::get_ident(p.node).get().to_string(),
2340+
PatIdent(_, ref p, _) => token::get_ident(p.node).to_string(),
23412341
PatEnum(ref p, _) => path_to_string(p),
23422342
PatStruct(ref name, ref fields, etc) => {
23432343
format!("{} {{ {}{} }}", path_to_string(name),
@@ -2487,11 +2487,11 @@ impl Clean<Stability> for attr::Stability {
24872487
fn clean(&self, _: &DocContext) -> Stability {
24882488
Stability {
24892489
level: self.level,
2490-
feature: self.feature.get().to_string(),
2490+
feature: self.feature.to_string(),
24912491
since: self.since.as_ref().map_or("".to_string(),
2492-
|interned| interned.get().to_string()),
2492+
|interned| interned.to_string()),
24932493
reason: self.reason.as_ref().map_or("".to_string(),
2494-
|interned| interned.get().to_string()),
2494+
|interned| interned.to_string()),
24952495
}
24962496
}
24972497
}

branches/tmp/src/librustdoc/html/highlight.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ fn doit(sess: &parse::ParseSess, mut lexer: lexer::StringReader,
142142

143143
// keywords are also included in the identifier set
144144
token::Ident(ident, _is_mod_sep) => {
145-
match token::get_ident(ident).get() {
145+
match &token::get_ident(ident)[] {
146146
"ref" | "mut" => "kw-2",
147147

148148
"self" => "self",

branches/tmp/src/librustdoc/visit_ast.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ impl<'a, 'tcx> RustdocVisitor<'a, 'tcx> {
237237
ast::ItemExternCrate(ref p) => {
238238
let path = match *p {
239239
None => None,
240-
Some((ref x, _)) => Some(x.get().to_string()),
240+
Some((ref x, _)) => Some(x.to_string()),
241241
};
242242
om.extern_crates.push(ExternCrate {
243243
name: name,
@@ -253,7 +253,7 @@ impl<'a, 'tcx> RustdocVisitor<'a, 'tcx> {
253253
let please_inline = item.attrs.iter().any(|item| {
254254
match item.meta_item_list() {
255255
Some(list) => {
256-
list.iter().any(|i| i.name().get() == "inline")
256+
list.iter().any(|i| &i.name()[] == "inline")
257257
}
258258
None => false,
259259
}

0 commit comments

Comments
 (0)