constructors for 1 or 2 elements fqueues

This commit is contained in:
Simon Cruanes 2014-07-04 02:02:03 +02:00
parent abef0be6bd
commit 1b98749c65
2 changed files with 7 additions and 0 deletions

View file

@ -56,6 +56,9 @@ let is_empty = function
| Shallow Zero -> true
| _ -> false
let singleton x = _single x
let doubleton x y = _double x y
let _empty = Lazy.from_val empty
let rec cons : 'a. 'a -> 'a t -> 'a t

View file

@ -38,6 +38,10 @@ val empty : 'a t
val is_empty : 'a t -> bool
val singleton : 'a -> 'a t
val doubleton : 'a -> 'a -> 'a t
exception Empty
val cons : 'a -> 'a t -> 'a t