package fmlib

  1. Overview
  2. Docs

Module String.To_sourceSource

Conversion of a string to a source of characters.

include Interfaces.SOURCE with type item = char
Sourcetype item = char

Type of items coming from the source.

Sourcetype t

t A stream of items.

Sourceval has_more : t -> bool

has_more s Does the stream s have more items?

Sourceval peek : t -> item

peek s Peek the next item from the stream s.

Precondition: has_more s

Sourceval advance : t -> t

advance s Pop the top item off the stream s.

Precondition: has_more s

Sourceval make : string -> t

make str A character stream generated from the string str.

OCaml

Innovation. Community. Security.