code: def _enumload(l: Loader, value, type_) -> Enum:
      
      try:
          # Try naïve conversion
          return type_(value)
      except:
          pass
  
      # Try with the typing hints
      for _, t in get_type_hints(type_).items():
          try:
              return type_(l.load(value, t))
          except:
              pass
      raise TypedloadValueError(
          'Value could not be loaded into %s' % type_,
          value=value,
          type_=type_
      )
docs: This loads something into an Enum.
  
      It tries with basic types first.
  
      If that fails, it tries to look for type annotations inside the
      Enum, and tries to use those to load the value into something
      that is compatible with the Enum.
  
      Of course if that fails too, a ValueError is raised.