Cakelisp doesn’t really have an interpreter. Cakelisp always generates C/C++ code to do meaningful work. This means the Cakelisp transpiler, macros, generators, and of course final code output can be debugged using a regular C/C++ debugger like GDB, LLDB, Or Visual Studio Debugger.
Run cakelisp --help
to see what command-line arguments may be passed in to control verbosity. If Cakelisp is doing something you don’t expect, it may help to turn on verbosity for the sub-system you expect may be at fault.
The following command may be run in order to tell GDB where the .so
files you want to debug are located:
set solib-search-path ~/Development/code/repositories/cakelisp/
set cwd ~/Development/code/repositories/cakelisp/
(adjust that path to where you installed cakelisp, of course).
By setting a breakpoint in already generated C++ code, you will then hit the breakpoint once the code is regenerated and loaded at transpiler runtime (a.k.a. compile-time code execution).