about summary refs log tree commit diff
path: root/src/libsyntax
diff options
context:
space:
mode:
authorJakub <jakub@jakub.cc>2013-09-08 22:43:58 +0000
committerJakub <jakub@jakub.cc>2013-09-08 22:44:24 +0000
commit7173b9d1b8475bf2b44e50b78501f45f98c76bc0 (patch)
tree6c2721874e4b9525874c9c03162bb00bfb3ee54c /src/libsyntax
parent79e78c4b0c49003c8191f7094651753ecfabfd24 (diff)
downloadrust-7173b9d1b8475bf2b44e50b78501f45f98c76bc0.tar.gz
rust-7173b9d1b8475bf2b44e50b78501f45f98c76bc0.zip
Fix pretty-printing of empty impl items
Diffstat (limited to 'src/libsyntax')
-rw-r--r--src/libsyntax/print/pprust.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/libsyntax/print/pprust.rs b/src/libsyntax/print/pprust.rs
index f440e0a1771..87920d93828 100644
--- a/src/libsyntax/print/pprust.rs
+++ b/src/libsyntax/print/pprust.rs
@@ -586,11 +586,13 @@ pub fn print_item(s: @ps, item: &ast::item) {
         };
 
         print_type(s, ty);
-        space(s.s);
 
         if methods.len() == 0 {
             word(s.s, ";");
+            end(s); // end the head-ibox
+            end(s); // end the outer cbox
         } else {
+            space(s.s);
             bopen(s);
             for meth in methods.iter() {
                print_method(s, *meth);