mirror of
https://github.com/nim-lang/Nim.git
synced 2025-12-29 01:14:41 +00:00
No implicit quit for Genode (#6515)
This commit is contained in:
committed by
Andreas Rumpf
parent
e40bf9036f
commit
2ca7b703fb
@@ -1013,10 +1013,9 @@ proc genMainProc(m: BModule) =
|
||||
ComponentConstruct =
|
||||
"void Libc::Component::construct(Libc::Env &env) {$N" &
|
||||
"\tgenodeEnv = &env;$N" &
|
||||
"\tLibc::with_libc([&] () {$n\t" &
|
||||
"\tLibc::with_libc([&] () {$N\t" &
|
||||
MainProcs &
|
||||
"\t});$N" &
|
||||
"\tenv.parent().exit(0);$N" &
|
||||
"}$N$N"
|
||||
|
||||
var nimMain, otherMain: FormatStr
|
||||
|
||||
@@ -312,7 +312,7 @@ proc ensureInitialized() =
|
||||
|
||||
if not testsToRun.isValid:
|
||||
testsToRun.init()
|
||||
when declared(os):
|
||||
when declared(paramCount):
|
||||
# Read tests to run from the command line.
|
||||
for i in 1 .. paramCount():
|
||||
testsToRun.incl(paramStr(i))
|
||||
|
||||
@@ -1436,7 +1436,8 @@ when defined(nimdoc):
|
||||
## <#GC_fullCollect>`_.
|
||||
##
|
||||
## The proc ``quit(QuitSuccess)`` is called implicitly when your nim
|
||||
## program finishes without incident. A raised unhandled exception is
|
||||
## program finishes without incident for platforms where this is the
|
||||
## expected behavior. A raised unhandled exception is
|
||||
## equivalent to calling ``quit(QuitFailure)``.
|
||||
##
|
||||
## Note that this is a *runtime* call and using ``quit`` inside a macro won't
|
||||
|
||||
Reference in New Issue
Block a user