Tags / 1 post
#deref-coercion
2024 1 post
-
Index out of bounds? Not always! - A Rusty Surprise
Indexing a two-element array out of bounds is a compile error, yet the same mistake through a reference, (&arr)[5], compiles.
Tags / 1 post
Indexing a two-element array out of bounds is a compile error, yet the same mistake through a reference, (&arr)[5], compiles.