about summary refs log tree commit diff
path: root/src/librustdoc/html/render.rs
diff options
context:
space:
mode:
authorPatrick Walton <pcwalton@mimiga.net>2014-01-10 14:02:36 -0800
committerHuon Wilson <dbau.pp+github@gmail.com>2014-02-02 01:44:48 +1100
commit8e52b85d5a6f6e3aaa2f15d7c1e907d0ce8589ee (patch)
treeafcac214c65f792304926a71117ffdf37a0fd060 /src/librustdoc/html/render.rs
parent70c5a0fbf784d6a89b1c2c50f9fe83093bd21abc (diff)
downloadrust-8e52b85d5a6f6e3aaa2f15d7c1e907d0ce8589ee.tar.gz
rust-8e52b85d5a6f6e3aaa2f15d7c1e907d0ce8589ee.zip
libsyntax: De-`@str` literal strings in the AST
Diffstat (limited to 'src/librustdoc/html/render.rs')
-rw-r--r--src/librustdoc/html/render.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/librustdoc/html/render.rs b/src/librustdoc/html/render.rs
index 2885d05a5bd..86b6a5734a5 100644
--- a/src/librustdoc/html/render.rs
+++ b/src/librustdoc/html/render.rs
@@ -45,6 +45,7 @@ use extra::arc::Arc;
 use extra::json::ToJson;
 use syntax::ast;
 use syntax::attr;
+use syntax::parse::token::InternedString;
 
 use clean;
 use doctree;
@@ -803,12 +804,13 @@ impl<'a> Item<'a> {
 impl<'a> fmt::Default for Item<'a> {
     fn fmt(it: &Item<'a>, fmt: &mut fmt::Formatter) {
         match attr::find_stability(it.item.attrs.iter()) {
-            Some(stability) => {
+            Some(ref stability) => {
                 write!(fmt.buf,
                        "<a class='stability {lvl}' title='{reason}'>{lvl}</a>",
                        lvl = stability.level.to_str(),
                        reason = match stability.text {
-                           Some(s) => s, None => @"",
+                           Some(ref s) => (*s).clone(),
+                           None => InternedString::new(""),
                        });
             }
             None => {}