V requires that any potentially memory-unsafe operations are marked intentionally. Marking them also indicates to anyone reading the code that there could be memory-safety violations if there was a mistake.
- Pointer arithmetic
- Conversion to pointer from an incompatible type
To mark potentially memory-unsafe operations, enclose them in an unsafe
block:
If you suspect your program does violate memory-safety, you have a head start on
finding the cause: look at the unsafe
blocks (and how they interact with
surrounding code).
- Note: This is work in progress.