]> git.lizzy.rs Git - rust.git/commitdiff
Fix pretty test
authorShotaro Yamada <sinkuu@sinkuu.xyz>
Wed, 5 Dec 2018 03:15:28 +0000 (12:15 +0900)
committerShotaro Yamada <sinkuu@sinkuu.xyz>
Wed, 5 Dec 2018 03:15:28 +0000 (12:15 +0900)
src/libsyntax/parse/lexer/comments.rs

index 92990ae2ef071abb8746cf0496f64c1da0ed6907..d3039326c8941d95c3c8cd0c8eaea1e534b7a77d 100644 (file)
@@ -211,7 +211,7 @@ fn all_whitespace(s: &str, col: CharPos) -> Option<usize> {
         if !ch.is_whitespace() {
             return None;
         }
-        idx = i;
+        idx = i + ch.len_utf8();
     }
     Some(idx)
 }