We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 39275ab + ad8a5d9 commit b468789Copy full SHA for b468789
rust-version
@@ -1 +1 @@
1
-nightly-2019-02-13
+nightly-2019-02-14
tests/run-pass/strings.rs
@@ -18,10 +18,17 @@ fn fat_pointer_on_32_bit() {
18
Some(5).expect("foo");
19
}
20
21
+fn str_indexing() {
22
+ let mut x = "Hello".to_string();
23
+ let _v = &mut x[..3]; // Test IndexMut on String.
24
+}
25
+
26
fn main() {
27
assert_eq!(empty(), "");
28
assert_eq!(hello(), "Hello, world!");
29
assert_eq!(hello_bytes(), b"Hello, world!");
30
assert_eq!(hello_bytes_fat(), b"Hello, world!");
31
32
fat_pointer_on_32_bit(); // Should run without crashing.
33
+ str_indexing();
34
0 commit comments