chore(RhinoScriptEngine): remove function print println

This commit is contained in:
Xwite
2023-03-25 12:22:34 +08:00
parent 4ad7e6f989
commit 06a74a5559
@@ -165,6 +165,7 @@ class RhinoScriptEngine : AbstractScriptEngine(), Invocable, Compilable {
val newScope: Scriptable = ExternalScriptable(ctxt, indexedProps) val newScope: Scriptable = ExternalScriptable(ctxt, indexedProps)
newScope.prototype = topLevel newScope.prototype = topLevel
newScope.put("context", newScope, ctxt) newScope.put("context", newScope, ctxt)
/*
val cx = Context.enter() val cx = Context.enter()
try { try {
@Language("js") @Language("js")
@@ -196,6 +197,7 @@ class RhinoScriptEngine : AbstractScriptEngine(), Invocable, Compilable {
} finally { } finally {
Context.exit() Context.exit()
} }
*/
newScope newScope
} }
} }
@@ -304,6 +306,7 @@ class RhinoScriptEngine : AbstractScriptEngine(), Invocable, Compilable {
private const val DEBUG = false private const val DEBUG = false
/*
@Language("js") @Language("js")
private val printSource = """ private val printSource = """
function print(str, newline) { function print(str, newline) {
@@ -323,6 +326,7 @@ class RhinoScriptEngine : AbstractScriptEngine(), Invocable, Compilable {
print(str, true); print(str, true);
} }
""".trimIndent() """.trimIndent()
*/
init { init {
ContextFactory.initGlobal(object : ContextFactory() { ContextFactory.initGlobal(object : ContextFactory() {