1995-08-09 08:06:35 -07:00
|
|
|
(***********************************************************************)
|
|
|
|
(* *)
|
2011-07-27 07:17:02 -07:00
|
|
|
(* OCaml *)
|
1995-08-09 08:06:35 -07:00
|
|
|
(* *)
|
|
|
|
(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *)
|
|
|
|
(* *)
|
1996-04-30 07:53:58 -07:00
|
|
|
(* Copyright 1996 Institut National de Recherche en Informatique et *)
|
1999-11-17 10:59:06 -08:00
|
|
|
(* en Automatique. All rights reserved. This file is distributed *)
|
|
|
|
(* under the terms of the Q Public License version 1.0. *)
|
1995-08-09 08:06:35 -07:00
|
|
|
(* *)
|
|
|
|
(***********************************************************************)
|
|
|
|
|
1995-05-04 03:15:53 -07:00
|
|
|
(* Detection of partial matches and unused match cases. *)
|
2012-05-30 07:52:37 -07:00
|
|
|
open Asttypes
|
1995-05-04 03:15:53 -07:00
|
|
|
open Typedtree
|
2012-05-30 07:52:37 -07:00
|
|
|
open Types
|
1995-05-04 03:15:53 -07:00
|
|
|
|
2012-09-27 05:32:54 -07:00
|
|
|
val pretty_const : constant -> string
|
2002-05-24 07:34:37 -07:00
|
|
|
val top_pretty : Format.formatter -> pattern -> unit
|
|
|
|
val pretty_pat : pattern -> unit
|
|
|
|
val pretty_line : pattern list -> unit
|
|
|
|
val pretty_matrix : pattern list list -> unit
|
|
|
|
|
2001-02-19 12:27:52 -08:00
|
|
|
val omega : pattern
|
|
|
|
val omegas : int -> pattern list
|
2000-08-11 12:58:52 -07:00
|
|
|
val omega_list : 'a list -> pattern list
|
2001-02-19 12:27:52 -08:00
|
|
|
val normalize_pat : pattern -> pattern
|
|
|
|
val all_record_args :
|
2012-10-24 05:03:00 -07:00
|
|
|
(Longident.t loc * label_description * pattern) list ->
|
|
|
|
(Longident.t loc * label_description * pattern) list
|
2012-09-18 23:57:17 -07:00
|
|
|
val const_compare : constant -> constant -> int
|
2000-08-11 12:58:52 -07:00
|
|
|
|
2001-02-19 12:27:52 -08:00
|
|
|
val le_pat : pattern -> pattern -> bool
|
|
|
|
val le_pats : pattern list -> pattern list -> bool
|
2000-08-11 12:58:52 -07:00
|
|
|
val compat : pattern -> pattern -> bool
|
|
|
|
val compats : pattern list -> pattern list -> bool
|
2001-02-19 12:27:52 -08:00
|
|
|
exception Empty
|
|
|
|
val lub : pattern -> pattern -> pattern
|
|
|
|
val lubs : pattern list -> pattern list -> pattern list
|
|
|
|
|
|
|
|
val get_mins : ('a -> 'a -> bool) -> 'a list -> 'a list
|
|
|
|
|
2013-04-25 06:32:17 -07:00
|
|
|
(* Those two functions recombine one pattern and its arguments:
|
2005-03-11 02:12:05 -08:00
|
|
|
For instance:
|
|
|
|
(_,_)::p1::p2::rem -> (p1, p2)::rem
|
|
|
|
The second one will replace mutable arguments by '_'
|
|
|
|
*)
|
2001-02-19 12:27:52 -08:00
|
|
|
val set_args : pattern -> pattern list -> pattern list
|
2005-03-11 02:12:05 -08:00
|
|
|
val set_args_erase_mutable : pattern -> pattern list -> pattern list
|
2001-02-19 12:27:52 -08:00
|
|
|
|
|
|
|
val pat_of_constr : pattern -> constructor_description -> pattern
|
|
|
|
val complete_constrs :
|
|
|
|
pattern -> constructor_tag list -> constructor_description list
|
2000-08-11 12:58:52 -07:00
|
|
|
|
2003-08-18 01:26:18 -07:00
|
|
|
val pressure_variants: Env.t -> pattern list -> unit
|
2013-04-15 09:23:22 -07:00
|
|
|
val check_partial: Location.t -> case list -> partial
|
2012-05-30 07:52:37 -07:00
|
|
|
val check_partial_gadt:
|
2012-10-24 05:03:00 -07:00
|
|
|
((string, constructor_description) Hashtbl.t ->
|
|
|
|
(string, label_description) Hashtbl.t ->
|
2012-05-30 07:52:37 -07:00
|
|
|
Parsetree.pattern -> pattern option) ->
|
2013-04-15 09:23:22 -07:00
|
|
|
Location.t -> case list -> partial
|
|
|
|
val check_unused: Env.t -> case list -> unit
|
2000-08-11 12:58:52 -07:00
|
|
|
|
2008-07-09 06:03:38 -07:00
|
|
|
(* Irrefutability tests *)
|
2008-06-16 02:08:55 -07:00
|
|
|
val irrefutable : pattern -> bool
|
2008-07-09 06:03:38 -07:00
|
|
|
val fluid : pattern -> bool
|