Documentation

Regex.Syntax.Hir

High-level intermediate representation for a regular expression. #

A high-level intermediate representation Syntax.Hir for a regular expression.

@[reducible, inline]
Equations
Instances For
    Equations
    • One or more equations did not get rendered due to their size.
    Instances For
      Equations
      • One or more equations did not get rendered due to their size.

      see UInt32.isValidChar

      Equations
      • One or more equations did not get rendered due to their size.
      Equations
      Instances For
        Equations
        Instances For
          Equations
          • cls1.union cls2 = { set := cls1.set.union cls2.set }
          Instances For
            Equations
            • cls1.intersection cls2 = { set := cls1.set.intersection cls2.set }
            Instances For
              Equations
              • cls1.difference cls2 = { set := cls1.set.difference cls2.set }
              Instances For
                Equations
                • cls1.symmetric_difference cls2 = { set := cls1.set.symmetric_difference cls2.set }
                Instances For
                  Equations
                  • cls.negate = { set := cls.set.negate }
                  Instances For
                    Equations
                    • One or more equations did not get rendered due to their size.
                    Instances For
                      inductive Syntax.Class :
                      Instances For
                        Equations
                        inductive Syntax.Look :

                        The high-level intermediate representation for a look-around assertion.

                        • Start: Syntax.Look

                          Match the beginning of text.

                        • End: Syntax.Look

                          Match the end of text.

                        • EndWithOptionalLF: Syntax.Look

                          Match the end of text (before optional newline).

                        • StartLF: Syntax.Look

                          Match the beginning of a line or the beginning of text.

                        • EndLF: Syntax.Look

                          Match the end of a line or the end of text.

                        • StartCRLF: Syntax.Look

                          Match the beginning of a line or the beginning of text.

                        • EndCRLF: Syntax.Look

                          Match the end of a line or the end of text.

                        • WordUnicode: Syntax.Look

                          Match a Unicode-aware word boundary.

                        • WordUnicodeNegate: Syntax.Look

                          Match a Unicode-aware negation of a word boundary.

                        • WordStartUnicode: Syntax.Look

                          Match the start of a Unicode word boundary.

                        • WordEndUnicode: Syntax.Look

                          Match the end of a Unicode word boundary.

                        • WordStartHalfUnicode: Syntax.Look

                          Match the start half of a Unicode word boundary.

                        • WordEndHalfUnicode: Syntax.Look

                          Match the end half of a Unicode word boundary.

                        • PreviousMatch: Syntax.Look

                          Match the end of the previous match or start of string.

                        • ClearMatches: Syntax.Look

                          Clear all matches.

                        Instances For
                          Equations
                          Instances For

                            A type that collects various properties of an HIR value.

                            Instances For
                              Equations
                              structure Syntax.Flags :

                              A translator's representation of a regular expression's flags at any given moment in time.

                              Instances For
                                Equations
                                • Syntax.instInhabitedFlags = { default := { case_insensitive := none, multi_line := none, dot_matches_new_line := none, swap_greed := none, crlf := none, extended := none } }
                                Equations
                                • One or more equations did not get rendered due to their size.

                                The high-level intermediate representation for a look-around assertion.

                                Instances For

                                  A concatenation of regular expressions.

                                  Instances For
                                    inductive Syntax.Capture :

                                    The high-level intermediate representation for a capturing group.

                                    Instances For
                                      inductive Syntax.HirKind :

                                      The underlying kind of an arbitrary [Hir] expression.

                                      Instances For
                                        inductive Syntax.Hir :

                                        A high-level intermediate representation (HIR) for a regular expression.

                                        Instances For
                                          Equations
                                          Instances For
                                            Equations
                                            Instances For
                                              Equations
                                              Instances For
                                                @[irreducible]
                                                Equations
                                                • One or more equations did not get rendered due to their size.
                                                Instances For
                                                  @[irreducible]
                                                  def Syntax.Hir.fold {α : Type u_1} [Inhabited α] [ToString α] (hir : Syntax.Hir) (f : αSyntax.Hirα) (init : α) :
                                                  α
                                                  Equations
                                                  Instances For

                                                    check if an hir contains .Lookaround

                                                    Equations
                                                    • One or more equations did not get rendered due to their size.
                                                    Instances For
                                                      Equations
                                                      inductive Syntax.Dot :

                                                      A type describing the different flavors of ..

                                                      • AnyChar: Syntax.Dot

                                                        Matches the UTF-8 encoding of any Unicode scalar value. This is equivalent to (?su:.) and also \p{any}.

                                                      • AnyCharExceptLF: Syntax.Dot

                                                        Matches the UTF-8 encoding of any Unicode scalar value except for \n. This is equivalent to (?u-s:.) and also [\p{any}--\n].

                                                      • AnyCharExceptCRLF: Syntax.Dot

                                                        Matches the UTF-8 encoding of any Unicode scalar value except for \r and \n. This is equivalent to (?uR-s:.) and also [\p{any}--\r\n].

                                                      Instances For
                                                        Equations
                                                        Instances For

                                                          An HirFrame is a single stack frame, represented explicitly, which is created for each item in the Ast that we traverse.

                                                          Instances For
                                                            Equations
                                                            Instances For
                                                              Equations
                                                              Instances For

                                                                Assert that the current stack frame is a Unicode class expression and return it.

                                                                Equations
                                                                Instances For

                                                                  Assert that the current stack frame is a repetition.

                                                                  Equations
                                                                  Instances For

                                                                    Assert that the current stack frame is a group.

                                                                    Equations
                                                                    Instances For