Is there a Break() function for debug?

Dear Experts,

I would like to break at certain line back to root prompt.
Is there a Break() function?
The .b <line_number> does not work for a macro before it is loaded.

Thanks,
Quan

Dear Quan,

To break inside a macro with '.b ’ you have to first load the macro and set the file:

root[] .L myMacro.C
root[] .f myMacro.C
root[] .b 15
root[] myMacro()
... // Should break execution at the line after 15

Note, however, that this is CINT functionality and it is not anymore available in ROOT 6.

G Ganis

Hi Ganis,

What if I have an unnamed macro:

{
	int a = 10;
	int b = 50;
	double x = a/b; // break here
}

[quote=“ganis”]Dear Quan,

To break inside a macro with '.b ’ you have to first load the macro and set the file:

root[] .L myMacro.C
root[] .f myMacro.C
root[] .b 15
root[] myMacro()
... // Should break execution at the line after 15

Note, however, that this is CINT functionality and it is not anymore available in ROOT 6.

G Ganis[/quote]