class_docstr: For the `Elixir language <http://elixir-lang.org>`_.
  
  .. versionadded:: 1.5
class_docstr_tok: ["For","the","`","Elixir","language","<","http",":","\/\/elixir-lang.org",">","`","_",".","..","versionadded",":",":","1.5"]
code: def gen_elixir_sigil_rules():
      # all valid sigil terminators (excluding heredocs)
      terminators = [
          (r"\{", r"\}", "cb"),
          (r"\[", r"\]", "sb"),
          (r"\(", r"\)", "pa"),
          (r"<", r">", "ab"),
          (r"/", r"/", "slas"),
          (r"\|", r"\|", "pipe"),
          ('"', '"', "quot"),
          ("'", "'", "apos"),
      ]
  
      # heredocs have slightly different rules
      triquotes = [(r'"""', "triquot"), (r"'''", "triapos")]
  
      token = String.Other
      states = {"sigils": []}
  
      for term, name in triquotes:
          states["sigils"] += [
              (
                  r"(~[a-z])(%s)" % (term,),
                  bygroups(token, String.Heredoc),
                  (name + "-end", name + "-intp"),
              ),
              (
                  r"(~[A-Z])(%s)" % (term,),
                  bygroups(token, String.Heredoc),
                  (name + "-end", name + "-no-intp"),
              ),
          ]
  
          states[name + "-end"] = [
              (r"[a-zA-Z]+", token, "#pop"),
              default("#pop"),
          ]
          states[name + "-intp"] = [
              (r"^\s*" + term, String.Heredoc, "#pop"),
              include("heredoc_interpol"),
          ]
          states[name + "-no-intp"] = [
              (r"^\s*" + term, String.Heredoc, "#pop"),
              include("heredoc_no_interpol"),
          ]
  
      for lterm, rterm, name in terminators:
          states["sigils"] += [
              (r"~[a-z]" + lterm, token, name + "-intp"),
              (r"~[A-Z]" + lterm, token, name + "-no-intp"),
          ]
          states[name + "-intp"] = gen_elixir_sigstr_rules(rterm, token)
          states[name + "-no-intp"] = gen_elixir_sigstr_rules(
              rterm, token, interpol=False
          )
  
      return states
  
file_path: catboost/contrib/python/Pygments/py2/pygments/lexers/erlang.py
imports: import re
  from pygments.lexer import Lexer, RegexLexer, bygroups, words, do_insertions, include, default
  from pygments.token import Text, Comment, Operator, Keyword, Name, String, Number, Punctuation, Generic
label_desc: Use image node_id 2 for calling the ElixirLexer obj's underlying member method code with example usage: obj.gen_elixir_sigil_rules() and returns: states