on master help sign in
Fixed mistake and added test
commit824d0e3ea266744b6bcfc23413c4447b693e1355 authorJan de Muijnck-Hughes <jfdm@st-andrews.ac.uk> dateMon 28 Sep 2015, 12:39 (11 years ago) parent44c5d61
5 files changed+25−3
idris.cabal+6−2 src/Pkg/PParser.hs+1−1 test/pkg001/Main.idr+8 test/pkg001/run+3 test/pkg001/test.ipkg+7
idris.cabal+6−2
@@ -140,7 +140,7 @@ Extra-source-files:
140140 libs/effects/Makefile
141141 libs/effects/effects.ipkg
142142 libs/effects/Effect/*.idr
143− libs/effects/Effect/Logging/*.idr
143+ libs/effects/Effect/Logging/*.idr
144144 libs/effects/*.idr
145145
146146 libs/pruviloj/Makefile
@@ -567,6 +567,10 @@ Extra-source-files:
567567 test/primitives003/*.idr
568568 test/primitives003/expected
569569
570+ test/pkg001/run
571+ test/pkg001/test.ipkg
572+ test/pkg001/*.idr
573+
570574 test/proof001/run
571575 test/proof001/*.idr
572576 test/proof001/expected
@@ -598,7 +602,7 @@ Extra-source-files:
598602 test/proof010/run
599603 test/proof010/*.idr
600604 test/proof010/expected
601−
605+
602606 test/proofsearch001/run
603607 test/proofsearch001/*.idr
604608 test/proofsearch001/expected
src/Pkg/PParser.hs+1−1
@@ -83,7 +83,7 @@ pClause = do reserved "executable"; lchar '=';
8383 <|> do reserved "pkgs"; lchar '=';
8484 ps <- sepBy1 (fst <$> identifier) (lchar ',')
8585 st <- get
86− let pkgs = pureArgParser $ map (\x -> unwords ["-p", x]) ps
86+ let pkgs = pureArgParser $ concatMap (\x -> ["-p", x]) ps
8787 put (st {idris_opts = pkgs ++ idris_opts st})
8888 <|> do reserved "modules"; lchar '=';
8989 ms <- sepBy1 (fst <$> iName []) (lchar ',')
test/pkg001/Main.idrnew file+8
@@ -0,0 +1,8 @@
1+module Main
2+
3+import Effects
4+import Effect.State
5+
6+
7+main : IO ()
8+main = putStrLn "CouCou!"
test/pkg001/runnew file+3
@@ -0,0 +1,3 @@
1+#!/usr/bin/env bash
2+idris $@ --build test.ipkg
3+rm -f *.ibc
test/pkg001/test.ipkgnew file+7
@@ -0,0 +1,7 @@
1+package test
2+
3+pkgs = effects
4+
5+opts = "--warnpartial --warnreach"
6+
7+modules = Main