docs: def remove_reference(type_):
      """removes reference from the type definition
  
      If type is not reference type, it will be returned as is.
      """
      nake_type = remove_alias(type_)
      if not is_reference(nake_type):
          return type_
  
      return nake_type.base