@used
def type_from_ast(ast_node: ast.AST, visitor: Optional['NameCheckVisitor']=None, ctx: Optional[Context]=None) -> Value:
    'Given an AST node representing an annotation, return a\n    :class:`Value <pyanalyze.value.Value>`.\n\n    :param ast_node: AST node to evaluate.\n\n    :param visitor: Visitor class to use. This is used in the default\n                    :class:`Context` to resolve names and show errors.\n                    This is ignored if `ctx` is given.\n\n    :param ctx: :class:`Context` to use for evaluation.\n\n    '
    if (ctx is None):
        ctx = _DefaultContext(visitor, ast_node)
    return _type_from_ast(ast_node, ctx)
Given an AST node representing an annotation, return a
:class:`Value <pyanalyze.value.Value>`.

:param ast_node: AST node to evaluate.

:param visitor: Visitor class to use. This is used in the default
                :class:`Context` to resolve names and show errors.
                This is ignored if `ctx` is given.

:param ctx: :class:`Context` to use for evaluation.
@used
def type_from_ast(ast_node: ast.AST, visitor: Optional['NameCheckVisitor']=None, ctx: Optional[Context]=None) -> Value:
    'Given an AST node representing an annotation, return a\n    :class:`Value <pyanalyze.value.Value>`.\n\n    :param ast_node: AST node to evaluate.\n\n    :param visitor: Visitor class to use. This is used in the default\n                    :class:`Context` to resolve names and show errors.\n                    This is ignored if `ctx` is given.\n\n    :param ctx: :class:`Context` to use for evaluation.\n\n    '
    if (ctx is None):
        ctx = _DefaultContext(visitor, ast_node)
    return _type_from_ast(ast_node, ctx)