trim down public api
[org.ibex.core.git] / src / org / ibex / js / Interpreter.java
index 3b4dd28..83ff539 100644 (file)
@@ -99,12 +99,7 @@ class Interpreter implements ByteCodes, Tokens {
             case DUP: stack.push(stack.peek()); break;
             case NEWSCOPE: scope = new JSScope(scope); break;
             case OLDSCOPE: scope = scope.getParentScope(); break;
-            case ASSERT: {
-                JS o = stack.pop();
-                if (JS.checkAssertions && !JS.toBoolean(o))
-                    throw je("ibex.assertion.failed");
-                break;
-            }
+            case ASSERT: if (!JS.toBoolean(stack.pop())) throw je("ibex.assertion.failed"); break;
             case BITNOT: stack.push(JS.N(~JS.toLong(stack.pop()))); break;
             case BANG: stack.push(JS.B(!JS.toBoolean(stack.pop()))); break;
             case NEWFUNCTION: stack.push(((JSFunction)arg)._cloneWithNewParentScope(scope)); break;