mirror of
https://github.com/nim-lang/Nim.git
synced 2026-04-19 22:10:33 +00:00
@@ -24,6 +24,7 @@ when not gotoBasedExceptions:
|
||||
proc popSafePoint {.compilerRtl, inl.} = discard
|
||||
proc pushCurrentException(e: ref Exception) {.compilerRtl, inl.} = discard
|
||||
proc popCurrentException {.compilerRtl, inl.} = discard
|
||||
proc closureIterSetExc(e: ref Exception) {.compilerRtl, inl.} = discard
|
||||
|
||||
# some platforms have native support for stack traces:
|
||||
const
|
||||
|
||||
@@ -159,6 +159,9 @@ proc popCurrentException {.compilerRtl, inl.} =
|
||||
currException = currException.up
|
||||
#showErrorMessage2 "B"
|
||||
|
||||
proc closureIterSetExc(e: ref Exception) {.compilerRtl, inl.} =
|
||||
currException = e
|
||||
|
||||
proc popCurrentExceptionEx(id: uint) {.compilerRtl.} =
|
||||
discard "only for bootstrapping compatbility"
|
||||
|
||||
|
||||
@@ -72,6 +72,9 @@ proc getCurrentExceptionMsg*(): string =
|
||||
proc setCurrentException*(exc: ref Exception) =
|
||||
lastJSError = cast[PJSError](exc)
|
||||
|
||||
proc closureIterSetExc(e: ref Exception) {.compilerRtl, benign.} =
|
||||
setCurrentException(e)
|
||||
|
||||
proc pushCurrentException(e: sink(ref Exception)) {.compilerRtl, inline.} =
|
||||
## Used to set up exception handling for closure iterators.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user