diff options
| author | Patrick Walton <pcwalton@mimiga.net> | 2014-01-15 17:15:39 -0800 |
|---|---|---|
| committer | Huon Wilson <dbau.pp+github@gmail.com> | 2014-02-02 01:44:48 +1100 |
| commit | b496d7bec2a79feab092e6b4e251f7b0cee2a6a6 (patch) | |
| tree | 30bc26c3763372bb231dc24f7e34d666aaa9a6fb /src/libsyntax/print | |
| parent | 8d6ef2e1b198461fde48565c7efdf92a83a33abd (diff) | |
| download | rust-b496d7bec2a79feab092e6b4e251f7b0cee2a6a6.tar.gz rust-b496d7bec2a79feab092e6b4e251f7b0cee2a6a6.zip | |
libsyntax: Make float literals not use `@str`
Diffstat (limited to 'src/libsyntax/print')
| -rw-r--r-- | src/libsyntax/print/pprust.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libsyntax/print/pprust.rs b/src/libsyntax/print/pprust.rs index 8bf439818a2..d2a388cc14d 100644 --- a/src/libsyntax/print/pprust.rs +++ b/src/libsyntax/print/pprust.rs @@ -2202,10 +2202,10 @@ pub fn print_literal(s: &mut State, lit: &ast::Lit) { word(&mut s.s, (i as u64).to_str_radix(10u)); } } - ast::LitFloat(f, t) => { - word(&mut s.s, f.to_owned() + ast_util::float_ty_to_str(t)); + ast::LitFloat(ref f, t) => { + word(&mut s.s, f.get() + ast_util::float_ty_to_str(t)); } - ast::LitFloatUnsuffixed(f) => word(&mut s.s, f), + ast::LitFloatUnsuffixed(ref f) => word(&mut s.s, f.get()), ast::LitNil => word(&mut s.s, "()"), ast::LitBool(val) => { if val { word(&mut s.s, "true"); } else { word(&mut s.s, "false"); } |
