You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
error: invalid initialization of non-const reference of type 'tySequence_qwqHTkRvwhrRyENtudHQ7g&' from an rvalue of type 'tySequence_qwqHTkRvwhrRyENtudHQ7g*'
The issue is some strange interaction with seq.add where the version of testin the importing module address-of's s erroneously, when a reference is expected:
add_MIAbjRZGBQlNfywJeCn8AQ((&s), ((NI) 0));
The version in the defining module is correct:
add_MIAbjRZGBQlNfywJeCn8AQ(s, ((NI) 0));
The text was updated successfully, but these errors were encountered:
I think I have a similar codegen bug with the same error message :
/home/rcaillaud/.cache/nim/mainDapo_r/@mstorage@sstorage@smodels.nim.cpp: In function ‘tySequence__48JTohSgTy339bRxHzUD8KA newSeq_storageZstorageZmodels_1332(NI)’:
/home/rcaillaud/.cache/nim/mainDapo_r/@mstorage@sstorage@smodels.nim.cpp:1383:58: error: invalid initialization of reference of type ‘tySequence__9apztJSmgERYU8fZOjI4pOg&’ from expression of type ‘tySequence__48JTohSgTy339bRxHzUD8KA’
newSeq_OOZOOZOOZlocalwsZnimfftw51Zfftw51_548(result, len);
^
In file included from /home/rcaillaud/.cache/nim/mainDapo_r/@mstorage@sstorage@smodels.nim.cpp:7:0:
/home/rcaillaud/.cache/nim/mainDapo_r/@mstorage@sstorage@smodels.nim.cpp:475:31: note: in passing argument 1 of ‘void newSeq_OOZOOZOOZlocalwsZnimfftw51Zfftw51_548(tySequence__9apztJSmgERYU8fZOjI4pOg&, NI)’
N_LIB_PRIVATE N_NIMCALL(void, newSeq_OOZOOZOOZlocalwsZnimfftw51Zfftw51_548)(tySequence__9apztJSmgERYU8fZOjI4pOg& s, NI len);
^
/home/rcaillaud/.choosenim/toolchains/nim-#devel/lib/nimbase.h:256:44: note: in definition of macro ‘N_NIMCALL’
# define N_NIMCALL(rettype, name) rettype name /* no modifier */
^~~~
This happens when I try to use --gc:orc on my code base (a few thousands line of code).
I'm trying to work on a minimal reproducible example to investigate (with no success so far). Happens with nim devel f8519657c43f458db9c915cec62c59022041eb05
The following generates invalid C/C++ when imported from another module (the declaring module compiles fine).
This works without newruntime and worked with newruntime in 0.19.4
Error:
The issue is some strange interaction with
seq.add
where the version oftest
in the importing module address-of'ss
erroneously, when a reference is expected:The version in the defining module is correct:
The text was updated successfully, but these errors were encountered: