package transept

  1. Overview
  2. Docs
Generalized parser combinator library

Install

Dune Dependency

Authors

Maintainers

Sources

0.1.0.tar.gz
sha256=670634cc4be9a297c0f7174b61136e528a9d58ceab3ed78d71ef4680e4721e8b
md5=292994b959f2c2a55b9c1b2e10a09211

doc/transept.stream/Transept_stream/Via_parser/index.html

Module Transept_stream.Via_parser

Define stream construction from parser.

Parameters

Signature

type 'a r

The abstract type used for the stream denotation.

The stream builder module with a parser as a source.

module Stream : Transept_specs.STREAM with type 'a t = 'a r and module Builder = Build_via_stream

The stream module with a parser as a source.

include module type of Stream
type 'a t = 'a r

The abstract type used for the stream denotation.

module Builder = Build_via_stream
val build : 'a Builder.t

Build a fresh Stream using the parametric parser and a stream.

val position : 'a t -> int

Provides the current absolute position in the stream. This reflect the number of read elements from the stream.

val is_empty : 'a t -> bool

Predicate checking is the stream has at least one element or not.

val next : 'a t -> 'a option * 'a t

Provide the next token if possible and the next stream.

OCaml

Innovation. Community. Security.