diff options
| author | Fabrice Le Fessant <Fabrice.Le_fessant@inria.fr> | 2012-05-03 10:07:04 +0000 |
|---|---|---|
| committer | Fabrice Le Fessant <Fabrice.Le_fessant@inria.fr> | 2012-05-03 10:07:04 +0000 |
| commit | 38ca9d6d09d3c706e91346784c03fc644d063bd0 (patch) | |
| tree | cd92ce7e510a09e56aa1ccabef992bcf05675130 | |
| parent | 14bb2a8dcfbe0d0087d8605607fbf1acda99abd8 (diff) | |
| download | ocaml-38ca9d6d09d3c706e91346784c03fc644d063bd0.tar.gz | |
Improved bin-annot, passes all the testsuite
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/4.00-with-binannot@12423 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
| -rw-r--r-- | Makefile | 4 | ||||
| -rwxr-xr-x | boot/ocamlc | bin | 6283550 -> 6284867 bytes | |||
| -rwxr-xr-x | boot/ocamldep | bin | 328964 -> 328974 bytes | |||
| -rwxr-xr-x | boot/ocamllex | bin | 175417 -> 175427 bytes | |||
| -rw-r--r-- | debugger/main.ml | 8 | ||||
| -rw-r--r-- | testsuite/tests/asmcomp/Makefile | 1 | ||||
| -rw-r--r-- | typing/env.mli | 4 | ||||
| -rw-r--r-- | typing/ident.mli | 2 | ||||
| -rw-r--r-- | typing/parmatch.ml | 4 | ||||
| -rw-r--r-- | typing/typeclass.ml | 4 | ||||
| -rw-r--r-- | typing/typecore.ml | 2 |
11 files changed, 16 insertions, 13 deletions
@@ -19,8 +19,8 @@ include stdlib/StdlibModules CAMLC=boot/ocamlrun boot/ocamlc -nostdlib -I boot CAMLOPT=boot/ocamlrun ./ocamlopt -nostdlib -I stdlib -I otherlibs/dynlink -COMPFLAGS=-strict-sequence -warn-error A $(INCLUDES) -LINKFLAGS= +COMPFLAGS=-g -strict-sequence -warn-error A $(INCLUDES) +LINKFLAGS=-g CAMLYACC=boot/ocamlyacc YACCFLAGS=-v diff --git a/boot/ocamlc b/boot/ocamlc Binary files differindex a83eeaff21..dbf37a5478 100755 --- a/boot/ocamlc +++ b/boot/ocamlc diff --git a/boot/ocamldep b/boot/ocamldep Binary files differindex 8e96bef097..9460373fb4 100755 --- a/boot/ocamldep +++ b/boot/ocamldep diff --git a/boot/ocamllex b/boot/ocamllex Binary files differindex e5bde09bc1..0bed2dc45b 100755 --- a/boot/ocamllex +++ b/boot/ocamllex diff --git a/debugger/main.ml b/debugger/main.ml index a02b0a02a2..1dcd5cf40a 100644 --- a/debugger/main.ml +++ b/debugger/main.ml @@ -104,9 +104,9 @@ let rec protect ppf restart loop = show_current_event ppf; restart ppf end) -(* | x -> + | x -> kill_program (); - raise x *) + raise x let execute_file_if_any () = let buffer = Buffer.create 128 in @@ -230,5 +230,5 @@ let main () = eprintf "@]@."; exit 2 -let _ = main () -(* Printexc.catch (Unix.handle_unix_error main) () *) +let _ = + Printexc.catch (Unix.handle_unix_error main) () diff --git a/testsuite/tests/asmcomp/Makefile b/testsuite/tests/asmcomp/Makefile index 9af720d916..fb1af49c96 100644 --- a/testsuite/tests/asmcomp/Makefile +++ b/testsuite/tests/asmcomp/Makefile @@ -44,6 +44,7 @@ OTHEROBJS=\ $(TOPDIR)/typing/includemod.cmo \ $(TOPDIR)/typing/parmatch.cmo \ $(TOPDIR)/typing/typetexp.cmo \ + $(TOPDIR)/typing/cmt_format.cmo \ $(TOPDIR)/typing/stypes.cmo \ $(TOPDIR)/typing/typecore.cmo \ $(TOPDIR)/typing/typedecl.cmo \ diff --git a/typing/env.mli b/typing/env.mli index 89a283f329..10213b40df 100644 --- a/typing/env.mli +++ b/typing/env.mli @@ -46,7 +46,7 @@ module EnvTbl : sig val keys : 'a t -> Ident.t list end -type t (* = { +type t = { values: (Path.t * value_description) EnvTbl.t; annotations: (Path.t * Annot.ident) EnvTbl.t; constrs: (Path.t * constructor_description) EnvTbl.t; @@ -93,7 +93,7 @@ and functor_components = { fcomp_subst: Subst.t; (* Prefixing substitution for the result signature *) fcomp_cache: (Path.t, module_components) Hashtbl.t (* For memoization *) } - *) + val empty: t val initial: t diff --git a/typing/ident.mli b/typing/ident.mli index e26490a9c3..f9e5754216 100644 --- a/typing/ident.mli +++ b/typing/ident.mli @@ -14,7 +14,7 @@ (* Identifiers (unique names) *) -type t +type t = { stamp: int; name: string; mutable flags: int } val create: string -> t val create_persistent: string -> t diff --git a/typing/parmatch.ml b/typing/parmatch.ml index 939d244bad..0710d42ad4 100644 --- a/typing/parmatch.ml +++ b/typing/parmatch.ml @@ -250,10 +250,10 @@ and pretty_lvals lbls ppf = function | [] -> () | [_, _,lbl,v] -> let name = find_label lbl lbls in - fprintf ppf "%a=%a" Ident.print name pretty_val v + fprintf ppf "%s=%a" (Ident.name name) pretty_val v | (_, _, lbl,v)::rest -> let name = find_label lbl lbls in - fprintf ppf "%a=%a;@ %a" Ident.print name pretty_val v (pretty_lvals lbls) rest + fprintf ppf "%s=%a;@ %a" (Ident.name name) pretty_val v (pretty_lvals lbls) rest let top_pretty ppf v = fprintf ppf "@[%a@]@?" pretty_val v diff --git a/typing/typeclass.ml b/typing/typeclass.ml index a9b3883351..218fe7cdf0 100644 --- a/typing/typeclass.ml +++ b/typing/typeclass.ml @@ -406,7 +406,9 @@ let rec class_type_field env self_type meths (fields, val_sig, concr_meths, inhe and class_signature env sty sign loc = let meths = ref Meths.empty in let self_cty = transl_simple_type env false sty in - let self_type = self_cty.ctyp_type in + let self_cty = { self_cty with + ctyp_type = Ctype.expand_head env self_cty.ctyp_type } in + let self_type = self_cty.ctyp_type in (* Check that the binder is a correct type, and introduce a dummy method preventing self type from being closed. *) diff --git a/typing/typecore.ml b/typing/typecore.ml index 625d198930..2eb66a7c8e 100644 --- a/typing/typecore.ml +++ b/typing/typecore.ml @@ -838,7 +838,7 @@ let rec type_pat ~constrs ~labels ~no_existentials ~mode ~env sp expected_ty = rp { pat_desc = Tpat_alias (p, TPat_constraint cty); pat_loc = loc; - pat_type = p.pat_type; + pat_type = ty; pat_env = p.pat_env } | Ppat_type lid -> let (path, p,ty) = build_or_pat !env loc lid.txt in |
