Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Debugging symbols in Erlang

I'm working my way through some simple programs for learning Erlang, and whenever I try to use the debugger I get "Invalid beam file or no abstract code: test_module" and nothing interesting happens. It looks to me like I'm compiling my modules without debugging symbols, but I can't seem to find how to fix it.

Here's what I do:

>c(test).
>debugger:quick(test, start, []).
** Invalid beam file or no abstract code: test

I feel like I must be missing something obvious. I have also tried this:

>debugger:start().

which pops up a nice looking window, but loading files (test.erl, test.beam) gives me similar error messages.

like image 260
nmichaels Avatar asked Oct 12 '10 15:10

nmichaels


1 Answers

you have to compile with debug_info, i.e.

compile:file("path/to/file.erl",[debug_info]).
like image 186
Lukas Avatar answered Sep 24 '22 19:09

Lukas