package morbig

  1. Overview
  2. Docs

Module HereDocument.LexerSource

Parameters

module U : sig ... end

Signature

Sourceval push_here_document_operator : bool -> CST.word CST.located ref -> unit

push_here_document_operator dashed word_ref registers a redirection operator:

  • dashed is true when the operator is <<-, and false if <<-
  • word_ref is a reference to a located word. This reference will later be assigned the contents of the here document.
Sourceval push_here_document_delimiter : string -> CST.word_cst -> unit

push_here_document_operator dashed word_ref registers a redirection operator:

  • dashed is true when the operator is <<-, and false if <<-
  • word_ref is a reference to a located word. This reference will later be assigned the contents of the here document.

push_here_document_delimiter word registers word as the delimiting word pertaining to the preceding redirection operator.

Sourceval start_here_document_lexing : unit -> unit

start scanning the here documents that we have registered.

start scanning the here documents that we have registered.

scans the contents of a here document including the line containing the delimiter. Returns the pretoken containing the contents of the here document. As a side effect, assigns the contents of the here document to the reference that was registered by push_here_document_operator.

Sourceval inside_here_document : unit -> bool

Are we currently reading a sequence of here documents?

Sourceval next_word_is_here_document_delimiter : unit -> bool

Are we currently reading a sequence of here documents?

Must the next word be a here document delimiter?

Sourceval next_line_is_here_document : unit -> bool

Must the next word be a here document delimiter?

Do we have to read here documents starting from the next line?

OCaml

Innovation. Community. Security.