Skip to content

Commit ece140a

Browse files
committed
add missing TruffleBoundary
1 parent 6165901 commit ece140a

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/modules/BuiltinFunctions.java

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1513,7 +1513,7 @@ public abstract static class BreakPointNode extends PythonBuiltinNode {
15131513

15141514
@Specialization
15151515
public Object doIt(VirtualFrame frame, Object[] args, PKeyword[] kwargs) {
1516-
if (Debugger.find(getContext().getEnv()).getSessionCount() > 0) {
1516+
if (getDebuggerSessionCount() > 0) {
15171517
// we already have a Truffle debugger attached, it'll stop here
15181518
return PNone.NONE;
15191519
} else {
@@ -1532,6 +1532,11 @@ public Object doIt(VirtualFrame frame, Object[] args, PKeyword[] kwargs) {
15321532
return callNode.execute(frame, breakpointhook, args, kwargs);
15331533
}
15341534
}
1535+
1536+
@TruffleBoundary
1537+
private int getDebuggerSessionCount() {
1538+
return Debugger.find(getContext().getEnv()).getSessionCount();
1539+
}
15351540
}
15361541

15371542
@Builtin(name = "__tdebug__", takesVarArgs = true)

0 commit comments

Comments
 (0)