src/jdk/nashorn/internal/runtime/DebuggerSupport.java
Print this page
*** 73,83 ****
/**
* Return the current context global.
* @return context global.
*/
static Object getGlobal() {
! return Context.getGlobalTrusted();
}
/**
* Call eval on the current global.
* @param scope Scope to use.
--- 73,83 ----
/**
* Return the current context global.
* @return context global.
*/
static Object getGlobal() {
! return Context.getGlobal();
}
/**
* Call eval on the current global.
* @param scope Scope to use.
*** 85,95 ****
* @param string String to evaluate.
* @param returnException true if exceptions are to be returned.
* @return Result of eval as string, or, an exception or null depending on returnException.
*/
static Object eval(final ScriptObject scope, final Object self, final String string, final boolean returnException) {
! final ScriptObject global = Context.getGlobalTrusted();
final ScriptObject initialScope = scope != null ? scope : global;
final Object callThis = self != null ? self : global;
final Context context = global.getContext();
try {
--- 85,95 ----
* @param string String to evaluate.
* @param returnException true if exceptions are to be returned.
* @return Result of eval as string, or, an exception or null depending on returnException.
*/
static Object eval(final ScriptObject scope, final Object self, final String string, final boolean returnException) {
! final ScriptObject global = Context.getGlobal();
final ScriptObject initialScope = scope != null ? scope : global;
final Object callThis = self != null ? self : global;
final Context context = global.getContext();
try {