Source

OCaml-Chip8 / src / option.ml

Full commit
Pierre Surply 580b59b 















(*
** option.ml for OCaml-Chip8 in /home/surply_p
** 
** Made by Pierre Surply
** <pierre.surply@gmail.com>
** 
** Started on  Sat Aug  4 22:28:30 2012 Pierre Surply
** Last update Sat Aug  4 22:28:49 2012 Pierre Surply
*)

let is_some = function
  | Some _ -> true
  | _ -> false

let get = function
  | Some x -> x
  | _ -> failwith "None option"