shithub: MicroHs

Download patch

ref: ea48ba6de673536e1fe7f64a2428d2ef66379df0
parent: bfea4e5ee9483831dc316f728acc702b39c593ea
author: Lennart Augustsson <lennart.augustsson@epicgames.com>
date: Mon Dec 18 06:02:31 EST 2023

More testing

--- a/.github/workflows/c-cpp.yml
+++ b/.github/workflows/c-cpp.yml
@@ -129,6 +129,9 @@
     - name: make nfib
       run: make CONF=unix-32 nfibtest
       shell: alpine.sh {0}
+    - name: make info
+      run: make CONF=unix-32 info
+      shell: alpine.sh {0}
 # segfaults :(
 #    - name: make everytestmhs
 #      run: make CONF=unix-32 everytestmhs
@@ -158,6 +161,9 @@
       shell: alpine.sh {0}
     - name: make nfib
       run: make CONF=unix-32 nfibtest
+      shell: alpine.sh {0}
+    - name: make info
+      run: make CONF=unix-32 info
       shell: alpine.sh {0}
 
   build-linux-emscripten:
--- a/Makefile
+++ b/Makefile
@@ -20,7 +20,7 @@
 GHCPROF= # -prof -fprof-late #-prof -fprof-auto
 GHCFLAGS= $(GHCEXTS) $(GHCINCS) $(GHCWARNS) $(GHCOPTS) $(GHCTOOL) $(GHCPKGS) $(GHCOUT) $(GHCPROF)
 #
-.PHONY:	clean bootstrap install ghcgen newmhs cachelib timecompile exampletest cachetest runtest runtestmhs everytest everytestmhs nfibtest
+.PHONY:	clean bootstrap install ghcgen newmhs cachelib timecompile exampletest cachetest runtest runtestmhs everytest everytestmhs nfibtest info
 
 all:	bin/mhs
 
@@ -113,12 +113,12 @@
 	@echo "*** Set environment variable MHSDIR to $(PREFIX)/lib/mhs"
 	@echo "***"
 
-everytest:	newmhs runtest exampletest cachetest bootcombtest nfibtest
+everytest:	newmhs runtest exampletest cachetest bootcombtest nfibtest info
 
-everytestmhs:	bin/mhs bin/mhseval exampletest cachetest bootstrap runtestmhs nfibtest
+everytestmhs:	bin/mhs bin/mhseval exampletest cachetest bootstrap runtestmhs nfibtest info
 
 runtestmhs:
-	cd tests; make MHS=../bin/mhs cache; make MHS="../bin/mhs +RTS -H2M -RTS -C" test
+	cd tests; make MHS=../bin/mhs cache; make MHS="../bin/mhs +RTS -H2M -RTS -C" info test
 
 bootcombtest:	bin/gmhs bin/mhseval
 	bin/gmhs -isrc -ogmhs.comb  MicroHs.Main
@@ -130,6 +130,9 @@
 	bin/mhs Example && bin/mhseval
 	bin/mhs Example -oEx && ./Ex && rm Ex
 
+info:	bin/mhs
+	bin/mhs -r -itests Info
+
 cachetest:	bin/mhs bin/mhseval Example.hs
 	rm -f .mhscache
 	bin/mhs -C AllOfLib
@@ -140,4 +143,4 @@
 	bin/mhs -itests Nfib && bin/mhseval
 
 emscripten: bin/mhs
-	make test -f Makefile.emscripten;
+	make test -f Makefile.emscripten
--- a/Makefile.emscripten
+++ b/Makefile.emscripten
@@ -35,7 +35,12 @@
 	CC='$(CC)' $(TMHS) Sieve -otests/Sieve.js && $(NODE) tests/Sieve.js > tests/Sieve.out && diff tests/Sieve.ref tests/Sieve.out
 	CC='$(CC)' $(TMHS) Dict -otests/Dict.js && $(NODE) tests/Dict.js > tests/Dict.out && diff tests/Dict.ref tests/Dict.out
 	CC='$(CC)' $(TMHS) Symbol -otests/Symbol.js && $(NODE) tests/Symbol.js > tests/Symbol.out && diff tests/Symbol.ref tests/Symbol.out
-
+	CC='$(CC)' $(TMHS) FunDep -otests/FunDep.js && $(NODE) tests/FunDep.js > tests/FunDep.out && diff tests/FunDep.ref tests/FunDep.out
+	CC='$(CC)' $(TMHS) TypeLits -otests/TypeLits.js && $(NODE) tests/TypeLits.js > tests/TypeLits.out && diff tests/TypeLits.ref tests/TypeLits.out
+	CC='$(CC)' $(TMHS) View -otests/View.js && $(NODE) tests/View.js > tests/View.out && diff tests/View.ref tests/View.out
+	CC='$(CC)' $(TMHS) IOArray -otests/IOArray.js && $(NODE) tests/IOArray.js > tests/IOArray.out && diff tests/IOArray.ref tests/IOArray.out
+	CC='$(CC)' $(TMHS) ST -otests/ST.js && $(NODE) tests/ST.js > tests/ST.out && diff tests/ST.ref tests/ST.out
+	CC='$(CC)' $(TMHS) Info -otests/Info.js && $(NODE) tests/Info.js
 
 clean:
 	rm -f tests/*.out tests/*.tmp tests/*.js
--- a/Makefile.windows
+++ b/Makefile.windows
@@ -18,3 +18,4 @@
 	bin\mhs Example && bin\mhseval
 #	bin\mhs Example -oEx.exe && Ex && rm Ex.exe
         bin\mhs -itests Nfib && bin\mhseval
+	bin\mhs -r -itests Info
--