#NEWLINE# def do_types_overlap( t1 , t2 ) : #NEWLINE# #INDENT# if ( t1 == t2 ) : #NEWLINE# #INDENT# return True #NEWLINE# #UNINDENT# if isinstance ( t1 , GraphQLObjectType ) : #NEWLINE# #INDENT# if isinstance ( t2 , GraphQLObjectType ) : #NEWLINE# #INDENT# return False #NEWLINE# #UNINDENT# return ( t1 in t2 . get_possible_types ( ) ) #NEWLINE# #UNINDENT# if ( isinstance ( t1 , GraphQLInterfaceType ) or isinstance ( t1 , GraphQLUnionType ) ) : #NEWLINE# #INDENT# if isinstance ( t2 , GraphQLObjectType ) : #NEWLINE# #INDENT# return ( t2 in t1 . get_possible_types ( ) ) #NEWLINE# #UNINDENT# t1_type_names = { t1_type_names . name : possible_type for possible_type in t1 . get_possible_types ( ) } #NEWLINE# return any ( ( ( t . name in t1_type_names ) for t in t2 . get_possible_types ( ) ) )