Merge pull request #377 from rgrinberg/reason-test-changes
Reason test changes
This commit is contained in:
commit
7b6db8a3c2
|
@ -1 +1 @@
|
|||
val y : unit -> int
|
||||
val run : unit -> unit
|
||||
|
|
|
@ -1 +1 @@
|
|||
let y = () => 42;
|
||||
let run = () => print_endline("Bar");
|
|
@ -0,0 +1 @@
|
|||
let run = fun () => print_endline("Cppome");
|
|
@ -0,0 +1 @@
|
|||
let run : unit => unit
|
|
@ -1 +1 @@
|
|||
let x = 43
|
||||
let run () = print_endline "Foo"
|
||||
|
|
|
@ -1 +1 @@
|
|||
let x : int
|
||||
let run : unit => unit;
|
|
@ -1,4 +1 @@
|
|||
|
||||
let hw = fun () => "hello world";
|
||||
|
||||
print_endline(hw());
|
||||
let run = fun () => print_endline("hello world");
|
|
@ -1,2 +1 @@
|
|||
|
||||
let hw : unit => string;
|
||||
let run : unit => unit;
|
|
@ -1,19 +1,31 @@
|
|||
(jbuild_version 1)
|
||||
|
||||
(rule (copy pped.pp.re pped.re))
|
||||
(rule (copy pped.rei.pp pped.rei))
|
||||
(rule (copy copy-sources/pped.pp.re pped.re))
|
||||
(rule (copy copy-sources/pped.rei.pp pped.rei))
|
||||
|
||||
(library
|
||||
((name rlib)
|
||||
(public_name rlib)
|
||||
(modules (bar cppome foo hello pped))
|
||||
(preprocess
|
||||
(per_module
|
||||
((pps (reasonppx)) (foo))
|
||||
((pps (reasonppx (-lint false))) (hello))
|
||||
((action (run ./pp/reasononlypp.exe ${<})) (cppome))))))
|
||||
|
||||
(executable
|
||||
((name rbin)
|
||||
(modules (rbin))
|
||||
(preprocess (action (run ./pp/reasononlypp.exe ${<})))
|
||||
(libraries (rlib))))
|
||||
|
||||
;; we want to make sure that .rei files are present
|
||||
(alias
|
||||
((name runtest)
|
||||
((name install-file)
|
||||
(deps (rlib.install))
|
||||
(action (echo "${read:rlib.install}"))))
|
||||
|
||||
(alias
|
||||
((name runtest)
|
||||
(deps (rbin.exe))
|
||||
(action (run ${<}))))
|
|
@ -0,0 +1,6 @@
|
|||
open Rlib;
|
||||
|
||||
Cppome.run();
|
||||
Hello.run();
|
||||
Bar.run();
|
||||
Foo.run();
|
|
@ -1,4 +1,4 @@
|
|||
$ $JBUILDER runtest -j1 --root .
|
||||
$ $JBUILDER build @runtest @install-file -j1 --root .
|
||||
refmt bar.re.ml
|
||||
ocamldep pp/reasononlypp.depends.ocamldep-output
|
||||
ocamldep ppx/reasonppx.depends.ocamldep-output
|
||||
|
@ -17,13 +17,16 @@
|
|||
ocamlopt ppx/reasonppx.{a,cmxa}
|
||||
reasononlypp cppome.pp.re
|
||||
reasononlypp cppome.pp.rei
|
||||
reasononlypp rbin.pp.re
|
||||
ocamlopt .ppx/reasonppx/ppx.exe
|
||||
refmt cppome.pp.re.ml
|
||||
refmt cppome.pp.re.mli
|
||||
refmt rbin.pp.re.ml
|
||||
ppx foo.pp.ml
|
||||
ppx hello.re.pp.ml
|
||||
ppx foo.re.pp.mli
|
||||
ppx hello.re.pp.mli
|
||||
ocamldep rbin.depends.ocamldep-output
|
||||
ocamldep rlib.depends.ocamldep-output
|
||||
ocamldep rlib.dependsi.ocamldep-output
|
||||
ocamlc rlib__Bar.{cmi,cmti}
|
||||
|
@ -41,8 +44,10 @@
|
|||
ocamlopt rlib__Hello.{cmx,o}
|
||||
ocamlc rlib__Pped.{cmo,cmt}
|
||||
ocamlopt rlib__Pped.{cmx,o}
|
||||
ocamlc rbin.{cmi,cmo,cmt}
|
||||
ocamlc rlib.cma
|
||||
ocamlopt rlib.{a,cmxa}
|
||||
ocamlopt rbin.{cmx,o}
|
||||
ocamlopt rlib.cmxs
|
||||
lib: [
|
||||
"_build/install/default/lib/rlib/META" {"META"}
|
||||
|
@ -81,3 +86,9 @@
|
|||
"_build/install/default/lib/rlib/rlib.a"
|
||||
"_build/install/default/lib/rlib/rlib.cmxs"
|
||||
]
|
||||
ocamlopt rbin.exe
|
||||
rbin alias runtest
|
||||
Cppome
|
||||
hello world
|
||||
Bar
|
||||
Foo
|
||||
|
|
Loading…
Reference in New Issue