class_docstr: The :class:`RegexPattern` class is an implementation of a pattern
  using regular expressions.
docstr: Tests the equality of this regex pattern with *other* (:class:`RegexPattern`)
  by comparing their :attr:`~Pattern.include` and :attr:`~RegexPattern.regex`
  attributes.
code: def __eq__(self, other):
      """
      Tests the equality of this regex pattern with *other* (:class:`RegexPattern`)
      by comparing their :attr:`~Pattern.include` and :attr:`~RegexPattern.regex`
      attributes.
      """
      if isinstance(other, RegexPattern):
          return (
              self.include == other.include
              and self.regex == other.regex
          )
      else:
          return NotImplemented
  
file_path: ray/python/ray/_private/thirdparty/pathspec/pattern.py
imports: import re
  from .compat import unicode
label_desc: Use image node_id 2 for calling the RegexPattern obj's underlying member method code with example usage: obj.__eq__(other) and returns: unknown, NotImplemented