def _update_types(node: Node, ref_type: Any, object_type: Optional[type]) -> None:
    if ((object_type is not None) and (not is_primitive_dict(object_type))):
        node._metadata.object_type = object_type
    if (node._metadata.ref_type is Any):
        _deep_update_type_hint(node, ref_type)
def _update_types(node: Node, ref_type: Any, object_type: Optional[type]) -> None:
    if ((object_type is not None) and (not is_primitive_dict(object_type))):
        node._metadata.object_type = object_type
    if (node._metadata.ref_type is Any):
        _deep_update_type_hint(node, ref_type)