mirror of
https://github.com/nim-lang/Nim.git
synced 2026-07-27 02:46:29 +00:00
Yield in try
This commit is contained in:
@@ -41,3 +41,6 @@ proc reraiseException() {.compilerRtl.} =
|
||||
proc writeStackTrace() = discard
|
||||
|
||||
proc setControlCHook(hook: proc () {.noconv.}) = discard
|
||||
|
||||
proc closureIterSetupExc(e: ref Exception) {.compilerproc, inline.} =
|
||||
sysFatal(ReraiseError, "exception handling is not available")
|
||||
|
||||
@@ -131,6 +131,10 @@ proc popCurrentExceptionEx(id: uint) {.compilerRtl.} =
|
||||
quitOrDebug()
|
||||
prev.up = cur.up
|
||||
|
||||
proc closureIterSetupExc(e: ref Exception) {.compilerproc, inline.} =
|
||||
if not e.isNil:
|
||||
currException = e
|
||||
|
||||
# some platforms have native support for stack traces:
|
||||
const
|
||||
nativeStackTraceSupported* = (defined(macosx) or defined(linux)) and
|
||||
|
||||
Reference in New Issue
Block a user