diff options
author | Araq <rumpf_a@web.de> | 2018-03-30 02:32:13 +0200 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2018-03-30 02:32:13 +0200 |
commit | 9de05ec3e04e8a2321b29896fe9fa7db4c6e65f3 (patch) | |
tree | 8667e2a5c64d93b29b748feaf29066d64fa925d1 /lib/system | |
parent | 1d9343080de8e19835c3f6568630ba759afbb94f (diff) | |
download | Nim-9de05ec3e04e8a2321b29896fe9fa7db4c6e65f3.tar.gz |
further steps in implementing sink parameters; refs #7041
Diffstat (limited to 'lib/system')
-rw-r--r-- | lib/system/chcks.nim | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/system/chcks.nim b/lib/system/chcks.nim index 69b680dbd..d3651f659 100644 --- a/lib/system/chcks.nim +++ b/lib/system/chcks.nim @@ -52,6 +52,11 @@ proc chckNil(p: pointer) = if p == nil: sysFatal(NilAccessError, "attempt to write to a nil address") +when defined(nimNewRuntime): + proc chckMove(b: bool) {.compilerproc.} = + if not b: + sysFatal(MoveError, "attempt to access an object that was moved") + proc chckNilDisp(p: pointer) {.compilerproc.} = if p == nil: sysFatal(NilAccessError, "cannot dispatch; dispatcher is nil") |