class SyntaxTree::Parser

def on_heredoc_beg(value)

on_heredoc_beg: (String value) -> HeredocBeg
:call-seq:
def on_heredoc_beg(value)
  location =
    Location.token(
      line: lineno,
      char: char_pos,
      column: current_column,
      size: value.size
    )
  # Here we're going to artificially create an extra node type so that if
  # there are comments after the declaration of a heredoc, they get printed.
  beginning = HeredocBeg.new(value: value, location: location)
  @heredocs << Heredoc.new(beginning: beginning, location: location)
  beginning
end