Add copyright notices and new function String.chomp
[ocaml.git] / bytecomp / translcore.mli
blob8148f9b8a623050514b03453a56deba8334ac313
1 (***********************************************************************)
2 (* *)
3 (* Objective Caml *)
4 (* *)
5 (* Xavier Leroy, projet Cristal, INRIA Rocquencourt *)
6 (* *)
7 (* Copyright 1996 Institut National de Recherche en Informatique et *)
8 (* en Automatique. All rights reserved. This file is distributed *)
9 (* under the terms of the Q Public License version 1.0. *)
10 (* *)
11 (***********************************************************************)
13 (* $Id$ *)
15 (* Translation from typed abstract syntax to lambda terms,
16 for the core language *)
18 open Asttypes
19 open Types
20 open Typedtree
21 open Lambda
23 val name_pattern: string -> (pattern * 'a) list -> Ident.t
25 val transl_exp: expression -> lambda
26 val transl_apply: lambda -> (expression option * optional) list -> lambda
27 val transl_let:
28 rec_flag -> (pattern * expression) list -> lambda -> lambda
29 val transl_primitive: Primitive.description -> lambda
30 val transl_exception:
31 Ident.t -> Path.t option -> exception_declaration -> lambda
33 val check_recursive_lambda: Ident.t list -> lambda -> bool
35 type error =
36 Illegal_letrec_pat
37 | Illegal_letrec_expr
38 | Free_super_var
40 exception Error of Location.t * error
42 open Format
44 val report_error: formatter -> error -> unit
46 (* Forward declaration -- to be filled in by Translmod.transl_module *)
47 val transl_module :
48 (module_coercion -> Path.t option -> module_expr -> lambda) ref
49 val transl_object :
50 (Ident.t -> string list -> class_expr -> lambda) ref