From be0c8cd59ba86d672bc75366591c55c3fce47239 Mon Sep 17 00:00:00 2001 From: Richard Feldman Date: Mon, 31 Aug 2020 23:22:00 -0400 Subject: [PATCH] clipp-w clipp-x clipp-y --- compiler/can/src/expr.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/compiler/can/src/expr.rs b/compiler/can/src/expr.rs index 40de55953e..6daebc1d77 100644 --- a/compiler/can/src/expr.rs +++ b/compiler/can/src/expr.rs @@ -1436,12 +1436,12 @@ fn flatten_str_lines<'a>( /// Resolve stirng interpolations by desugaring a sequence of StrSegments /// into nested calls to Str.concat -fn desugar_str_segments<'a>(var_store: &mut VarStore, segments: Vec) -> Expr { +fn desugar_str_segments(var_store: &mut VarStore, segments: Vec) -> Expr { use StrSegment::*; let mut iter = segments.into_iter().rev(); let mut loc_expr = match iter.next() { - Some(Plaintext(string)) => Located::new(0, 0, 0, 0, Expr::Str(string.into())), + Some(Plaintext(string)) => Located::new(0, 0, 0, 0, Expr::Str(string)), Some(Interpolation(loc_expr)) => loc_expr, None => { // No segments? Empty string! @@ -1452,7 +1452,7 @@ fn desugar_str_segments<'a>(var_store: &mut VarStore, segments: Vec) for seg in iter { let loc_new_expr = match seg { - Plaintext(string) => Located::new(0, 0, 0, 0, Expr::Str(string.into())), + Plaintext(string) => Located::new(0, 0, 0, 0, Expr::Str(string)), Interpolation(loc_interpolated_expr) => loc_interpolated_expr, };