Get rid of more deprecation warnings by renaming exceptions

This commit is contained in:
def 2015-01-27 11:58:15 +01:00
commit 7894f50a56
2 changed files with 4 additions and 4 deletions

View file

@ -11,7 +11,7 @@
proc raiseRangeError(val: BiggestInt) {.compilerproc, noreturn, noinline.} = proc raiseRangeError(val: BiggestInt) {.compilerproc, noreturn, noinline.} =
when hostOS == "standalone": when hostOS == "standalone":
sysFatal(EOutOfRange, "value out of range") sysFatal(RangeError, "value out of range")
else: else:
sysFatal(RangeError, "value out of range: ", $val) sysFatal(RangeError, "value out of range: ", $val)
@ -44,7 +44,7 @@ proc chckRangeF(x, a, b: float): float =
return x return x
else: else:
when hostOS == "standalone": when hostOS == "standalone":
sysFatal(EOutOfRange, "value out of range") sysFatal(RangeError, "value out of range")
else: else:
sysFatal(RangeError, "value out of range: ", $x) sysFatal(RangeError, "value out of range: ", $x)

View file

@ -33,10 +33,10 @@ proc quitOrDebug() {.inline.} =
quit(1) quit(1)
proc raiseException(e: ref Exception, ename: cstring) {.compilerRtl.} = proc raiseException(e: ref Exception, ename: cstring) {.compilerRtl.} =
sysFatal(ENoExceptionToReraise, "exception handling is not available") sysFatal(ReraiseError, "exception handling is not available")
proc reraiseException() {.compilerRtl.} = proc reraiseException() {.compilerRtl.} =
sysFatal(ENoExceptionToReraise, "no exception to reraise") sysFatal(ReraiseError, "no exception to reraise")
proc writeStackTrace() = discard proc writeStackTrace() = discard