Open diegomrsantos opened 1 year ago
!nim c
import std/[streams, exitprocs]
type Test = ref object of RootObj
strm: Stream
var t = Test(strm: newFileStream("temp.txt", fmWrite))
proc p() =
for s in @["a", "b"]:
t.strm.writeLine(s)
addExitProc(p)
@juancarlospaco (contributor)devel :-1: FAIL
Output
Error: Command failed: nim c --run -d:strip -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --threads:off --verbosity:0 --hints:off --warnings:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim
Traceback (most recent call last)
/home/runner/.choosenim/toolchains/nim-#devel/lib/std/exitprocs.nim callClosures
/home/runner/work/Nim/Nim/temp.nim p
/home/runner/.choosenim/toolchains/nim-#devel/lib/pure/streams.nim writeLine
/home/runner/.choosenim/toolchains/nim-#devel/lib/pure/streams.nim write
/home/runner/.choosenim/toolchains/nim-#devel/lib/pure/streams.nim writeData
SIGSEGV: Illegal storage access. (Attempt to read from nil?)
Segmentation fault (core dumped)
Error: execution of an external program failed: '/home/runner/work/Nim/Nim/temp'
2023-07-11T19:43:18Z
2023-07-11T19:44:33
2023-07-11T19:44:34
1 minute
nim c --run -d:strip -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --threads:off --verbosity:0 --hints:off --warnings:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim
2023-07-11T19:43:18Z
2023-07-11T19:44:35
2023-07-11T19:44:36
1 minute
nim c --run -d:strip -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --threads:off --verbosity:0 --hints:off --warnings:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim
2023-07-11T19:43:18Z
2023-07-11T19:44:39
2023-07-11T19:44:40
1 minute
nim c --run -d:strip -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --threads:off --verbosity:0 --hints:off --warnings:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim
2023-07-11T19:43:18Z
2023-07-11T19:44:43
2023-07-11T19:44:45
2 minutes
nim c --run -d:strip -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --threads:off --verbosity:0 --hints:off --warnings:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim
Error: Command failed: nim c --run -d:strip -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --threads:off --verbosity:0 --hints:off --warnings:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim
/home/runner/work/Nim/Nim/temp.nim(1, 11) Error: cannot open file: std/exitprocs
2023-07-11T19:43:18Z
2023-07-11T19:45:00
2023-07-11T19:45:00
now
nim c --run -d:strip -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --threads:off --verbosity:0 --hints:off --warnings:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim
Error: Command failed: nim c --run -d:strip -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --threads:off --verbosity:0 --hints:off --warnings:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim
/home/runner/work/Nim/Nim/temp.nim(1, 11) Error: cannot open file: std/exitprocs
2023-07-11T19:43:18Z
2023-07-11T19:45:13
2023-07-11T19:45:13
now
nim c --run -d:strip -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --threads:off --verbosity:0 --hints:off --warnings:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim
Error: Command failed: nim c --run -d:strip -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --threads:off --verbosity:0 --hints:off --warnings:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim
/home/runner/work/Nim/Nim/temp.nim(1, 11) Error: cannot open file: std/exitprocs
2023-07-11T19:43:18Z
2023-07-11T19:45:24
2023-07-11T19:45:24
now
nim c --run -d:strip -d:ssl -d:nimDisableCertificateValidation --forceBuild:on --colors:off --threads:off --verbosity:0 --hints:off --warnings:off --lineTrace:off --nimcache:/home/runner/work/Nim/Nim --out:/home/runner/work/Nim/Nim/temp /home/runner/work/Nim/Nim/temp.nim
ringabout introduced a bug at 2022-09-23 19:05:05 +0800
on commit #7739e2342 with message:
defaults to ORC (#19972)
* defaults to Orc
* bootstrap using refc
* use gc
* init orc defines
* unregister orc
* fix gc
* fix commands
* add prepareMutation for orc
* enable deepcopy for orc
* prepareMutation
* more fixes
* some cases
* bug #20081
* partial fixes
* partial fixes
* fixes command line
* more fixes
* build Nim with refc
* use gc
* more fixes
* rstore
* orc doesn't support threadpool
* more shallowCopy
* more fixes
* fixes unsafeNew
* workarounds
* small
* more fixes
* fixes some megatest
* tcodegenbugs1 refc
* fxies megatest
* build nimble with refc
* workaround tensordsl tests
* replace shallowCopy with move
* fixes action
* workaround
* add todo
* fixes important packages
* unpublic unregisterArcOrc
* fixes cpp
* enable windows
Co-authored-by: xflywind <43030857+xflywind@users.noreply.github.com>
The bug is in the files:
.github/workflows/ci_docs.yml
compiler/commands.nim
compiler/nim.nim
compiler/options.nim
koch.nim
lib/system/iterators.nim
nimsuggest/sexp.nim
testament/categories.nim
testament/important_packages.nim
tests/assign/moverload_asgn2.nim
tests/async/tasync_traceback.nim
tests/ccgbugs/t13062.nim
tests/ccgbugs/tassign_nil_strings.nim
tests/ccgbugs/tcodegenbug1.nim
tests/ccgbugs/tdeepcopy_addr_rval.nim
tests/ccgbugs/thtiobj.nim
tests/ccgbugs/tmissinginit.nim
tests/ccgbugs/tmissingvolatile.nim
tests/collections/tseq.nim
tests/concepts/t3330.nim
tests/concepts/tusertypeclasses.nim
tests/destructor/tatomicptrs.nim
tests/errmsgs/t10376.nim
tests/exception/tcpp_imported_exc.nim
tests/generics/tgeneric3.nim
tests/generics/tparam_binding.nim
tests/gensym/tgensymgeneric.nim
tests/ic/config.nims
tests/iter/tshallowcopy_closures.nim
tests/macros/tstaticparamsmacro.nim
tests/magics/t10307.nim
tests/magics/tmagics.nim
tests/manyloc/keineschweine/keineschweine.nim.cfg
tests/manyloc/keineschweine/lib/estreams.nim
tests/metatype/tmetatype_various.nim
tests/metatype/tstaticparammacro.nim
tests/metatype/tstaticvector.nim
tests/misc/taddr.nim
tests/misc/tnew.nim
tests/misc/trunner_special.nim
tests/misc/tunsignedconv.nim
tests/modules/tmodule_name_clashes.nim
tests/niminaction/Chapter3/various3.nim
tests/objects/t4318.nim
tests/objects/tobj_asgn_dont_slice.nim
tests/objects/tobjconstr.nim
tests/parallel/tconvexhull.nim
tests/parallel/tdeepcopy.nim
tests/parallel/tdeepcopy2.nim
tests/parallel/tdisjoint_slice1.nim
tests/parallel/tflowvar.nim
tests/parallel/tinvalid_array_bounds.nim
tests/parallel/tmissing_deepcopy.nim
tests/parallel/tnon_disjoint_slice1.nim
tests/parallel/tparfind.nim
tests/parallel/tpi.nim
tests/parallel/tsendtwice.nim
tests/parallel/tsysspawn.nim
tests/parallel/tuseafterdef.nim
tests/parallel/twaitany.nim
tests/parser/t12274.nim
tests/pragmas/t12640.nim
tests/pragmas/tnoreturn.nim
tests/stdlib/mgenast.nim
tests/stdlib/tgenast.nim
tests/stdlib/thttpclient_ssl.nim
tests/stdlib/tjson.nim
tests/stdlib/tmitems.nim
tests/stdlib/tstdlib_various.nim
tests/stdlib/tstring.nim
tests/stdlib/twchartoutf8.nim
tests/system/tdeepcopy.nim
tests/template/twrongmapit.nim
tests/threads/tjsthreads.nim
tests/threads/tonthreadcreation.nim
tests/typerel/t4799_1.nim
tests/typerel/t4799_2.nim
tests/typerel/t4799_3.nim
tests/typerel/ttypedesc_as_genericparam1.nim
tests/typerel/ttypedesc_as_genericparam1_orc.nim
tests/typerel/ttypedesc_as_genericparam2.nim
The bug can be in the commits:
(Diagnostics sometimes off-by-one).
42 minutes
bisecting 1580
commits at 38
commits per second.
What happened?
Executing
nim c -r test2.nim
for the code below causes a runtime error.Possibly related to https://github.com/nim-lang/Nim/issues/19795 and https://github.com/nim-lang/Nim/issues/20800
Nim Version
Nim Compiler Version 1.7.3 [MacOSX: amd64] Compiled at 2022-11-14 Copyright (c) 2006-2022 by Andreas Rumpf
git hash: d73fff1ecc858783a3f1a90830e1bad4a3a23737 active boot switches: -d:release
Current Standard Output Logs
Expected Standard Output Logs
Possible Solution
No response
Additional Information
Works fine on:
Nim Compiler Version 1.6.8 [MacOSX: amd64] Compiled at 2022-10-27 Copyright (c) 2006-2021 by Andreas Rumpf
active boot switches: -d:release