PhpParser\Lexer::resetErrors PHP Method

resetErrors() protected method

protected resetErrors ( )
    protected function resetErrors()
    {
        if (function_exists('error_clear_last')) {
            error_clear_last();
        } else {
            // set error_get_last() to defined state by forcing an undefined variable error
            set_error_handler(function () {
                return false;
            }, 0);
            @$undefinedVariable;
            restore_error_handler();
        }
    }