zero-plusplus / vscode-autohotkey-debug

https://marketplace.visualstudio.com/items?itemName=zero-plusplus.vscode-autohotkey-debug
52 stars 4 forks source link

Behaviour of the breakpoint in Fat Arrow Function #315

Open zero-plusplus opened 8 months ago

zero-plusplus commented 8 months ago

Assigning a Fat Arrow Function to a variable and specifying a breakpoint on that line (in this example, line 1) will break at two different times: on assignment and on call.

1| add := (a, b) => a + b;
2| add(1, 2)

Usually, this problem is solved with inline breakpoint. However, that is a feature that is not available in the AutoHotkey debugger (or rather, there is no inline breakpoint section in DBGp, which is adopted by the AutoHotkey debugger).

This problem can be solved if in-line breakpoints can be implemented in a pseudo-instrumental way. However, this feature must be implemented as an option, as it overrides the behaviour of the official AutoHotkey debugger.