def __init__(self, tree, filename='(none)', builtins=None, ignore_lines=(), **settings):
        self.settings = settings
        self.ignore_errors = settings.get('ignore_frosted_errors', [])
        self.ignore_lines = ignore_lines
        file_specific_ignores = settings.get('ignore_frosted_errors_for_' + (os.path.basename(filename) or ""), None)
        if file_specific_ignores:
            self.ignore_errors += file_specific_ignores

        self._node_handlers = {}
        self._deferred_functions = []
        self._deferred_assignments = []
        self.dead_scopes = []
        self.messages = []
        self.filename = filename
        if builtins:
            self.frosted_builtins = self.frosted_builtins.union(builtins)
        self.scope_stack = [ModuleScope()]
        self.except_handlers = [()]
        self.futures_allowed = True
        self.root = tree
        self.handle_children(tree)
        self.run_deferred(self._deferred_functions)
        self._deferred_functions = None
        self.run_deferred(self._deferred_assignments)
        self._deferred_assignments = None
        del self.scope_stack[1:]
        self.pop_scope()
        self.check_dead_scopes()
        self.check_plugins()