about summary refs log tree commit diff
path: root/src/string.rs
diff options
context:
space:
mode:
authortopecongiro <seuchida@gmail.com>2017-10-31 15:03:46 +0900
committertopecongiro <seuchida@gmail.com>2017-10-31 15:03:46 +0900
commit7e99893e25c900ceb8b61c6c69e8a46d3e604c1d (patch)
treed6fcc7c4ca85541421dd00d8e443ae3f0f7f2072 /src/string.rs
parent371d2bb939914e60bc7b3410157f9d6f639f6ccc (diff)
Use visual indent only when rewriting string literal
Diffstat (limited to 'src/string.rs')
-rw-r--r--src/string.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/string.rs b/src/string.rs
index 9812b8af611..c3f1c5faf1e 100644
--- a/src/string.rs
+++ b/src/string.rs
@@ -50,7 +50,7 @@ pub fn rewrite_string<'a>(orig: &str, fmt: &StringFormat<'a>) -> Option<String>
     let stripped_str = re.replace_all(orig, "$1");
 
     let graphemes = UnicodeSegmentation::graphemes(&*stripped_str, false).collect::<Vec<&str>>();
-    let shape = fmt.shape.visual_indent(0);
+    let shape = fmt.shape;
     let indent = shape.indent.to_string(fmt.config);
     let punctuation = ":,;.";