Dear Ivan,

Unfortunately the error did not go away, after the correction (delete[] where 
needed) still error free execution in R console but abort of the R process in 
Rstudio.

The debugger of RStudio did not give any useful information anymore. I then 
installed Drmingw and attached the R process of Rstudio to it.
When I then execute the tests everything happens error free ...
... until I close the debugger: then RStudio says that there is a fatal error 
in the R process and aborts it.

So of course I cannot find a cause this way!

Maybe you have an idea how to deal with this?



Luc

________________________________
Van: Ivan Krylov <ikry...@disroot.org>
Verzonden: dinsdag 12 november 2024 22:33
Aan: Luc De Wilde <luc.dewi...@ugent.be>
CC: r-package-devel@r-project.org <r-package-devel@r-project.org>
Onderwerp: Re: [R-pkg-devel] New package with C++ code causes R abort in 
RStudio, not in R console.

� Tue, 12 Nov 2024 21:09:54 +0000
Luc De Wilde <luc.dewi...@ugent.be> �����:

> I have attached a debugger (from Visual Studio) to the R process,
> which gives me the message "A breakpoint instruction (__debugbreak()
> statement or similar call) was executed in rsession-utf8.exe.
>
> When I go to the dll module in the Call Stack I get the message
> "Binary was not built with debug information".

So the crash does happen inside lavaanC.dll, did I get this right?

If you set the environment variable DEBUG to a non-empty string before
compiling the package, the resulting *.dll will have debug information
in the DWARF format (this is set in file.path(R.home('etc'), 'x64',
'Makeconf')). Visual Studio might not work with it, so you could
install gdb into Rtools using pacman, or you could try to give the
executable to Dr. Mingw 
<https://eur03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fjrfonseca%2Fdrmingw&data=05%7C02%7CLuc.DeWilde%40UGent.be%7C74c6b594e5414ac8486c08dd03619cae%7Cd7811cdeecef496c8f91a1786241b99c%7C1%7C0%7C638670439969607386%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=hiUfEIBkezT%2FoWd%2FC5ZJncKFkTNUZPmqiavOCLOzOUM%3D&reserved=0<https://github.com/jrfonseca/drmingw>>.

--
Best regards,
Ivan

        [[alternative HTML version deleted]]

______________________________________________
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel

Reply via email to