ocaml-llists /

Filename Size Date modified Message
92 B
155 B
26.4 KB
1.2 KB
1.3 KB
16.1 KB
16.5 KB
20.2 KB
20.5 KB
39.8 KB
1.8 KB
1. Description

This OCaml package provides lazy lists for OCaml. The features are as follows:
  * lazy lists library
  * syntax extension with support for
      - lazy list construction and generation
      - lazy list comprehension
      - parallel lazy list comprehension
      - lazy list pattern matching

Usage examples for original syntax see in examples/llistcons_orig.ml,
examples/llistcomp_orig.ml; for revised syntax - in examples/llistcons_rev.ml,

Documentation for lazy list library see in doc/index.html.

2. Installation Instructions

As usual
  sudo make install

For compiling and running tests:
  make tests
  make runtests

3. Usage

Compilation of program test.ml that uses lazy lists:
  * Original syntax:
      ocamlc -c -pp "camlp4o pa_llistcomp.cma" test.ml
  * Revised syntax:
      ocamlc -c -pp "camlp4r pa_llistcomp.cma" test.ml

And linking:
  ocamlc lazy_list.cmo test.cmo -o test

Using in toplevel (original syntax):

  #load "camlp4o.cma" ;;
  #load "pa_llistcomp.cma" ;;
  #load "lazy_list.cmo" ;;

Using in toplevel (revised syntax):

  #load "camlp4r.cma" ;;
  #load "pa_llistcomp.cma" ;
  #load "lazy_list.cmo" ;

Comments are very welcome.

Vadim Shender
vadim at shender dot org