Questions tagged [ocamldebug]
7 questions
3
votes
1 answer
Creating debug builds of Ocaml code with Jbuilder
I have been reading the tutorials for the Ocaml language and for Jbuilder. The official tutorial indicates that one must compile Ocaml code using the '-g' flag with ocamlc in order to then run ocamldebug.
I cannot find any mention of debug builds…

Vishakh
- 1,168
- 1
- 11
- 20
3
votes
1 answer
How to launch program with arguments in ocamldebug?
I want to give ocamldebug a try. How can I run a program in it with a set of arguments? I can't find anything related in the reference documentation.[1]
In GDB, I would enter run arg1...argn. Unfortunately it doesn't seem to work in ocamldebug.
$…

Antoine
- 1,782
- 1
- 14
- 32
0
votes
1 answer
How do I install a printer for a user-defined type in ocamldebug?
I've written a print function for a type in my program, and can load it into ocamldebug with load_printer, but can't install it with install_printer. What am I missing?
Here's the entirety of the file printtest.ml, which is the printer:
begin
…

Tim Leonard
- 153
- 6
0
votes
0 answers
Why does ocamldebug's install_printer report "Unbound identifier"?
I've written print functions (print_id, for example) for several types in my program, and have loaded them into ocamldebug (with 'load_printer _build/default/print.cma') but when I try to install them (with 'install_printer print_id' or…

Tim Leonard
- 153
- 6
0
votes
1 answer
How to view datas in classes via Ocamldebug?
I'm using OCamldebug to debug OCaml program of version 4.01.0. Just as debug info followed, the debugger breaks at line 61(where indicated as "<|b|>"). When i was trying to view data inside class "re". The debugger just print the type info instead…

S1mple
- 35
- 6
0
votes
1 answer
Fatal error: debugger does not support channel locks
I am trying to use ocamldebug with my project, to understand why a 3rd party lib I'm using is not behaving the way I expected.
https://ocaml.org/manual/debugger.html
The OCaml debugger is invoked by running the program ocamldebug with the name of…

Anentropic
- 32,188
- 12
- 99
- 147
0
votes
1 answer
Command line arguments to ocamldebug
How can I pass command line arguments to ocaml debugger? I am looking for something similar to gdbs --args, or r ..., or params ... <. For example, after compiling
open Printf;;
let () =
for i = 0 to Array.length Sys.argv - 1 do
printf…

Rorschach
- 31,301
- 5
- 78
- 129