Skip to content
Browse files

* tests/ml/cmt/let_scope.ml: new pb

  • Loading branch information...
1 parent 65be734 commit 963cc43497f60a55202ef4412cf3d88505584b22 @aryx aryx committed Dec 7, 2012
Showing with 15 additions and 1 deletion.
  1. +1 −1 tests/ml/cmt/Makefile
  2. +11 −0 tests/ml/cmt/let_scope.ml
  3. +3 −0 tests/ml/cmt/pervasives.ml
View
2 tests/ml/cmt/Makefile
@@ -8,7 +8,7 @@ SRC=pervasives.ml list.ml hashtbl.ml \
namespace_type_value.ml namespace_type_field.ml \
letrec.ml typerec.ml letrec_nested.ml \
alias_type_function.ml use_hashtbl.ml \
- dupe_exn.ml
+ dupe_exn.ml let_scope.ml
# not handled well
# functor.ml \
View
11 tests/ml/cmt/let_scope.ml
@@ -0,0 +1,11 @@
+open Pervasives
+
+let global = ref 0
+
+let use_global () =
+ let global =
+ match !global with
+ | 0 -> 1
+ | _ -> 2
+ in
+ global
View
3 tests/ml/cmt/pervasives.ml
@@ -7,4 +7,7 @@ type 'a ref = { mutable contents : 'a }
external ref : 'a -> 'a ref = "%makemutable"
+external ( ! ) : 'a ref -> 'a = "%field0"
+
external incr : int ref -> unit = "%incr"
+

0 comments on commit 963cc43

Please sign in to comment.
Something went wrong with that request. Please try again.