int[] linep = { 0 }; String filename = getSourcePositionFromStack(linep); Context.reportError(message, filename, linep[0], null, 0);
Context cx = getCurrentContext(); if (cx != null) { cx.getErrorReporter().error(message, sourceName, lineno, lineSource, lineOffset); } else { throw new EvaluatorException(message, sourceName, lineno, lineSource, lineOffset); }
    public static void reportError(String message)    {        int[] linep = { 0 };        String filename = getSourcePositionFromStack(linep);        Context.reportError(message, filename, linep[0], null, 0);    }