From 490821ef30cacb04a38edee09900d28a9d484374 Mon Sep 17 00:00:00 2001 From: Marcus Klaas Date: Sat, 5 Sep 2015 14:00:16 +0200 Subject: [PATCH] Work with spanned labels in break and continue --- src/expr.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/expr.rs b/src/expr.rs index e11c6e470f6..aac13f552d0 100644 --- a/src/expr.rs +++ b/src/expr.rs @@ -119,14 +119,14 @@ impl Rewrite for ast::Expr { // `continue` ast::Expr_::ExprAgain(ref opt_ident) => { let id_str = match *opt_ident { - Some(ident) => format!(" {}", ident), + Some(ident) => format!(" {}", ident.node), None => String::new(), }; Some(format!("continue{}", id_str)) } ast::Expr_::ExprBreak(ref opt_ident) => { let id_str = match *opt_ident { - Some(ident) => format!(" {}", ident), + Some(ident) => format!(" {}", ident.node), None => String::new(), }; Some(format!("break{}", id_str))