hackwaly / ocamlearlybird

OCaml debug adapter
MIT License
208 stars 23 forks source link

Breakpoints not hit when using libraries in sub-folders #11

Open varunpatro opened 5 years ago

varunpatro commented 5 years ago

Here's my folder structure:

bin/main.m 
lib/a.ml
lib/b.ml

I'm using dune to build an executable in the bin/ folder and a library in the lib/ folder.

When I use vscode to debug, I'm able to set breakpoints in the bin/main.ml and when the program starts, it pauses at those breakpoints. However, if I set breakpoints in the lib/a.ml file, the program doesn't pause when it reaches the line in lib/a.ml.

However, when I set a breakpoint in bin/main.ml and debug, if I use the debug controls such as step-over, i am able to reach the lines in lib/a.ml but setting breakpoints in lib/a.ml still doesn't work.

hackwaly commented 5 years ago

Try add dotMerlins config option to launch configuration. Don't forget add the one in subfolder. There's example in README.md

SteveBronder commented 4 years ago

It's telling me for dotMerlins "Property dotMerlins" is not allowed"

Info on version I installed from vscode below. Is there a more up to date version I should be using?

Name: OCaml Debugger Id: hackwaly.ocaml-debugger Description: OCaml debugger. Version: 0.1.2 Publisher: hackwaly VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=hackwaly.ocaml-debugger

victorvianna commented 4 years ago

@SteveBronder cf https://github.com/hackwaly/vscode-ocaml-debugger/issues/10 https://github.com/hackwaly/vscode-ocaml-debugger/pull/11