diff options
author | Jasper Ras <jras@hostnet.nl> | 2025-08-05 08:53:21 +0200 |
---|---|---|
committer | Jasper Ras <jras@hostnet.nl> | 2025-08-05 08:53:21 +0200 |
commit | 295b343aecf330e830d79f06e0efc511e7d76da1 (patch) | |
tree | 85057ef1fe401adcd0d958ddf6ff966f25d8fef0 /Undefined behaviour is caught by the compiler.md | |
parent | f43372529e655f3b039946c969e4465193eb2042 (diff) |
vault backup: 2025-08-05 08:53:21
Diffstat (limited to 'Undefined behaviour is caught by the compiler.md')
-rw-r--r-- | Undefined behaviour is caught by the compiler.md | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Undefined behaviour is caught by the compiler.md b/Undefined behaviour is caught by the compiler.md new file mode 100644 index 0000000..62adbff --- /dev/null +++ b/Undefined behaviour is caught by the compiler.md @@ -0,0 +1,10 @@ +[[Rust]] +[[What is a segmentation fault]] + +Undefined behaviour is prevented by compiler checks. For example we can't use an undefined variable in a function call. If that were unchecked it's behaviour is undefined: +- it could cause a segvault +- it could cause no harm +- it could become the target of a hack + +A list of behaviours considered undefined: +https://doc.rust-lang.org/reference/behavior-considered-undefined.html
\ No newline at end of file |