Evaluator function call caused high CPU usage

While playing with the new evaluator functions, I noticed code execution would stop after a function call.

No errors, no crashes, but after looking for a bug a bit Opus used 60% of my CPU. Exiting Opus brought everything back to normal, and it never happened again.

I ran the code from an open button while editing.

I've mailed the memory dumps.

The code snippet:

Output(selpath);
tabToActivate = FindTabIndex(selpath);

// execution stopped here

Output("tabToActivate: " + tabToActivate);

if (tabToActivate == -1) {
	cmd = "Go PATH=""" + selpath + """";
} else {
	cmd = "Go TABSELECT=" + tabToActivate;
}

Output(cmd);


function FindTabIndex(thePath){
	Output("thePath: " + thePath);
    for (i = 0; i < tabcount; i++) {
		Output(i + " | " + TabPath(i));
        if (TabPath(i) == thePath) return i;
    }
    return -1;
}