]> git.lizzy.rs Git - rust.git/blobdiff - tests/target/expr.rs
Merge pull request #1757 from topecongiro/rfc/combine-array
[rust.git] / tests / target / expr.rs
index aad9f6d1b5fb0ae270217386c47a95b686709858..3b275d30f4ced3b7ec6e2a2562ba41ab56549f50 100644 (file)
@@ -365,3 +365,18 @@ fn issue1714() {
     v = &mut { v }[mid..];
     let (left, right) = { v }.split_at_mut(mid);
 }
+
+// Multi-lined index should be put on the next line if it fits in one line.
+fn issue1749() {
+    {
+        {
+            {
+                if self.shape[(r as f32 + self.x_offset) as usize]
+                    [(c as f32 + self.y_offset) as usize] != 0
+                {
+                    // hello
+                }
+            }
+        }
+    }
+}