def visit_forwardref_type(self, t: ForwardRef) -> None: self.indicator['forward'] = True if t.resolved is None: resolved = self.anal_type(t.unbound) t.resolve(resolved) assert t.resolved is not None t.resolved.accept(self)
def visit_forwardref_type(self, t: ForwardRef) -> None: self.indicator['forward'] = True # mypyc plays badly with the janky failure to realize # t.resolved is changed, so keep it from figuring out that it # is None if (t.resolved is None) is True: resolved = self.anal_type(t.unbound) t.resolve(resolved) assert t.resolved is not None t.resolved.accept(self)
def visit_forwardref_type(self, t: ForwardRef) -> None: self.indicator['forward'] = True if t.resolved is None: resolved = self.anal_type(t.unbound) t.resolve(resolved)