summary refs log tree commit diff stats
path: root/lib/system/excpt.nim
Commit message (Collapse)AuthorAgeFilesLines
* fixes another effect inference bug [backport:1.6] (#19100)Andreas Rumpf2021-11-071-5/+8
| | | | * fixes another effect inference bug [backport:1.6]
* use lent (#18638)flywind2021-08-081-2/+2
|
* fix #18620 (#18624)flywind2021-08-011-4/+1
| | | | | * fix #18620 * add testcase
* fixes #18411 (#18432) [backport:1.4]Andreas Rumpf2021-07-051-3/+1
|
* Revert "system/excpt: check if the exception is not nil before pop (#18247)" ↵Andreas Rumpf2021-06-171-3/+2
| | | | | (#18265) This reverts commit 0adb47aa15e242983c8251d85367c0fe45fc5f12.
* system/excpt: check if the exception is not nil before pop (#18247)alaviss2021-06-141-2/+3
| | | | | | | | | | In CPS we would consume an exception in the except branch by stashing it into a local then remove the exception from Nim environment so as not to leak it to other code that would be running before the continuation continues However since popCurrentException() assumes that the exception always exist, removing the exception from an except branch will cause a SIGSEGV to happen. This commit fixes that.
* Fix C++ compilation error in excpt.nim (#17951)Danil Yarantsev2021-05-061-1/+1
|
* system.nim cleanup some exported constants which should never have be… ↵Andreas Rumpf2021-05-011-1/+1
| | | | | | (#17909) * system.nim cleanup some exported constants which should never have been exported
* fix #17749 ignore SIGPIPE signals, fix nim CI #17748 (#17752)Timothee Cour2021-04-181-3/+13
| | | | | * fix #17749 SIGPIPE * fix for windows
* IC: green tests (#17311)Andreas Rumpf2021-03-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * IC: renamed to_packed_ast module to ic module * IC: don't store the --forceBuild flag, makes it easier to test * IC: enable hello world test * Codegen: refactorings for IC; changed the name mangling algorithm * fixed the HCR regressions * life is too short for HCR * tconvexhull is now allowed to use deepCopy * IC exposed a stdlib bug, required a refactoring * codegen: code cleanups * IC: even if a module is outdated, its dependencies might come from disk * IC: progress * IC: better name mangling, module IDs are not stable * IC: another refactoring helping with --ic:on --gc:arc * disable arraymancer on Windows for the time being * disable arraymancer altogether * IC: make basic test work with 'nim cpp' * IC: progress on --ic:on --gc:arc * wip; name mangling for type info
* IC: further progress (#17150)Andreas Rumpf2021-03-051-3/+0
| | | | | | | * IC: respect the -f switch * IC: better rod file inspection * progress
* Replace double backticks with single backticks - Part 1 out of ~6 (#17205)Danil Yarantsev2021-02-281-4/+4
|
* system/excpt: let the OS handle termination on signal (#16712)alaviss2021-02-191-1/+11
|
* add -d:nimStrictMode in CI to keep code from regressing; fixes ↵Timothee Cour2021-02-171-1/+2
| | | | ConvFromXtoItselfNotNeeded, UnusedImport notes (#16764)
* remove all uses of condsyms symbols defined prior to bootstrap nim 0.20.0 ↵Timothee Cour2021-02-171-7/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (#16918) * nimNoArrayToCstringConversion deadcode * nimbabel deadcode * nimHasalignOf deadcode * nimvarargstyped deadcode * nimhygiene deadcode * nimNewTypedesc deadcode * nimlocks deadcode * nimHasCppDefine deadcode * nimHasRunnableExamples deadcode * nimHasNilChecks deadcode * nimSymKind deadcode * minor macros refactoring * nimVmEqIdent deadcode * nimNoNil deadcode * nimNoZeroTerminator deadcode * nimHasSymOwnerInMacro deadcode * nimVmExportFixed deadcode * nimNewRuntime deadcode * nimAshr deadcode * nimUncheckedArrayTyp deadcode * nimHasTypeof deadcode * nimErrorProcCanHaveBody deadcode * nimHasHotCodeReloading deadcode * nimHasSignatureHashInMacro deadcode * nimHasDefault deadcode * nimMacrosSizealignof deadcode
* use typeof instead type (#16962)flywind2021-02-081-1/+1
|
* fix partially #13115 (now works for cpp; but still fails for js on openbsd) ↵Timothee Cour2020-12-111-10/+22
| | | | | | (#16167) * fix partially #13115 properly (works for c,js,cpp,vm; still fails for js on openbsd) * address comment: also test with -d:danger, -d:debug
* fix #13115 (#15930)flywind2020-11-271-10/+15
| | | | | * fix #13115 * fix testament
* micro improvements (#15849)Andreas Rumpf2020-11-051-1/+2
|
* Fixes compilation for --os:any + --exception:setjmp (#15626)Dominik Picheta2020-10-201-1/+1
|
* better nativestacktrace support; refs #15284; backport [1.2] (#15384)Andreas Rumpf2020-09-221-25/+20
| | | | | | | | | | | | | | | | | * nimStackTraceOverride: enable stack traces in exceptions This is a two-step stack trace collection scheme, because re-raised exceptions will collect multiple stack traces but use them rarely, when printing info about an uncaught exception, so it makes sense to only do the cheap stack unwinding all the time and the relatively expensive debugging information collection on-demand. `asyncfutures` implements its own `$` proc for printing `seq[StackTraceEntry]`, so we have to add the debugging info there, just like we do for the private `$` proc in `system/excpt`. * cleaned up PR #15284 Co-authored-by: Ștefan Talpalaru <stefantalpalaru@yahoo.com>
* fixes #14370 (#14371)Andreas Rumpf2020-05-161-1/+1
|
* fixes #13881Andreas Rumpf2020-05-121-0/+8
| | | | | | * fixes #13881 * documented changed requirements for system.onThreadDestruction * destructors.rst: update the documentation
* do not track 'raise Defect' in the .raises: [] clause anymore (#14298)Andreas Rumpf2020-05-111-1/+6
| | | | | | | | | * do not track 'raise Defect' in the .raises: [] clause anymore * --panics:on maps 'raise Defect' to an unrecoverable fatal error * make tests green again * update the documentation too
* fix js stacktraces, unify all file,line,col formatting into a single ↵Timothee Cour2020-05-051-5/+3
| | | | | function (#14230) * fix https://github.com/timotheecour/Nim/issues/135 ; unify all file,line,col formatting into a single function
* Error -> Defect for defects (#13908)Jacek Sieka2020-04-281-1/+1
| | | | | | | | | | | | | | * Error -> Defect for defects The distinction between Error and Defect is subjective, context-dependent and somewhat arbitrary, so when looking at an exception, it's hard to guess what it is - this happens often when looking at a `raises` list _without_ opening the corresponding definition and digging through layers of inheritance. With the help of a little consistency in naming, it's at least possible to start disentangling the two error types and the standard lib can set a good example here.
* added extended msg for failed library loads w/ incorrect DLL formats (#13950)awr12020-04-161-2/+4
| | | | | | | | | | | | | | | * added extended msg for failed library loads w/ incorrect DLL formats * missing colon * fix GetLastError() * make GetLastError() available for windows console apps * remove premature nullchar if outputting extra message * if-protect nullchar detection * better fix for message box code
* stacktraces can now show custom runtime msgs per frame (#13351)Timothee Cour2020-03-301-2/+22
| | | | | | | | * stacktraces can now show custom runtime msgs * improve tests/stdlib/tstackframes.nim * fix test for --gc:arc * test --stacktraceMsgs:on and --stacktraceMsgs:off * --stacktracemsgs:off by default
* Attempt to finish off araq cpp exceptions (#13695)cooldome2020-03-191-26/+6
| | | | | | | | | | | | | | | * config update * disable a questionable test * remove c++ exception handling IDs, new impl doesn't require it anymore * C++ based exceptions finally work * fixes bootstrapping problem in C++ mode * teach GCC it's 2020 now * more bugfixes for C++ based exception handling * apply cooldome's patch * another attempt to enable C++11 * bug fix Co-authored-by: Araq <rumpf_a@web.de> Co-authored-by: cooldome <ariabushenko@bk.ru>
* rewritten goto based exception handling; much cleaner implementation;… ↵Andreas Rumpf2020-03-171-3/+3
| | | | | | (#13677) * rewritten goto based exception handling; much cleaner implementation; fixes #13668
* make goto based exceptions available for 'nim cpp' (#13244)Andreas Rumpf2020-01-251-4/+4
| | | | | * make goto based exceptions available for 'nim cpp' * optimize seq.add to be comparable to C++'s emplace_back
* Added 'ansic' os support for minimal (embedded) targets (#13088)Ico Doornekamp2020-01-151-53/+54
| | | | | | | | * os:any implementation * os:asny: omit flock/funlock calls in echoBinSafe * Disabled default "unhandled expection" reporting for `--os:any` to reduce code size. Added unhandledExceptionHook instead which can be used to get a notification from Nim and handle it from the application.
* fixes #13070Araq2020-01-101-2/+2
|
* --exception:goto switch for deterministic exception handling (#12977)Andreas Rumpf2020-01-011-95/+101
| | | | | This implements "deterministic" exception handling for Nim based on goto instead of setjmp. This means raising an exception is much cheaper than in C++'s table based implementations. Supports hard realtime systems. Default for --gc:arc and the C target because it's generally a good idea and arc is all about deterministic behavior. Note: This implies that fatal runtime traps are not catchable anymore! This needs to be documented.
* generic stack trace overriding mechanism (#12922)Ștefan Talpalaru2019-12-291-10/+33
| | | | | | | | | | | | | | | | * libbacktrace support * switch to a generic stack trace overriding mechanism When "nimStackTraceOverride" is defined, once of the imported modules can register its own procedure to replace the default stack trace generation by calling `registerStackTraceOverride(myOwnProc)`. Tested with `./koch boot -d:release --debugger:native -d:nimStackTraceOverride --import:libbacktrace` for the compiler itself and `./bin/nim c -r -f --stacktrace:off --debugger:native -d:nimStackTraceOverride --import:libbacktrace foo.nim` for an external program. * make the StackTraceOverrideProc {.noinline.}
* ARC related bugfixes and refactorings (#12781)Andreas Rumpf2019-12-051-8/+56
|
* make tests green againAndreas Rumpf2019-11-131-2/+2
|
* gc:arc: support GC_ref/unref for ref TAraq2019-11-131-2/+2
|
* Fix crash in terminate handler (#12572) [backport]Volodymyr Lashko2019-11-071-0/+6
| | | | | | | | | | | | | | | | * fix undefined behavior in terminate handler * fix failing unit test * Revert "fix failing unit test" This reverts commit 0e5e385fbf972d53909347e246a2e9b018fe9906. * Revert "fix undefined behavior in terminate handler" This reverts commit 2b582871f1981492838cc70d30e8c0e00ab8c9a9. * do not throw inside terminate handler with msvc < 1923
* first implementation of the new --seqsv2 switchAraq2019-10-201-1/+1
|
* Remove ENDB (#12095)Clyybber2019-08-311-11/+1
|
* Reset closure iter exception before rethrowingYuriy Glukhov2019-08-161-2/+1
|
* Merge branch 'cpp_reraise_fix' into yield-in-try-fixYuriy Glukhov2019-08-161-6/+9
|\
| * fixes #11118Andrii Riabushenko2019-04-301-6/+9
| |
* | [other] preparations for --styleCheck:error for the Nim compiler (#11478)Andreas Rumpf2019-06-121-6/+7
| |
* | Implements pending future tracking in async.Dominik Picheta2019-05-061-0/+6
|/
* fixes #10765 (#10993) [backport]cooldome2019-04-111-4/+21
|
* attempt to make the CIs green againAraq2019-04-021-5/+1
|
* do not display stacktrace twice, fixes #10922 (#10939)Miran2019-04-021-1/+0
|
* use abort instead of quit (#10872)Arne Döring2019-03-211-3/+8
|