Browse files

When given the --make option, do not pass it to ghc.

  • Loading branch information...
1 parent 7402bc6 commit d11cbb2043ac08a7849ff3beb516cbb6e2be12f8 @23Skidoo committed Mar 21, 2012
Showing with 2 additions and 1 deletion.
  1. +2 −1 Main.hs
View
3 Main.hs
@@ -85,13 +85,14 @@ getGhcArgs argv = let (as, fs) = getGhcArgs' argv [] []
eatOption (x:xs) as = (xs, x:as)
getGhcArgs' [] as fs = (as, fs)
- -- Options not passed to GHC: -o, -j, -vv, --ghc-path.
+ -- Options not passed to GHC: -o, -j, -vv, --ghc-path, --make.
getGhcArgs' ("-j":_:xs) as fs = getGhcArgs' xs as fs
getGhcArgs' ("-o":_:xs) as fs = getGhcArgs' xs as fs
getGhcArgs' (('-':'v':'v':_:[]):xs) as fs = getGhcArgs' xs as fs
getGhcArgs' ("--ghc-path":_:xs) as fs = getGhcArgs' xs as fs
getGhcArgs' (x:xs) as fs
| "--ghc-path=" `isPrefixOf` x = getGhcArgs' xs as fs
+ getGhcArgs' ("--make":xs) as fs = getGhcArgs' xs as fs
getGhcArgs' xs@(('-':_):_) as fs = let (xs', as') = eatOption xs as
in getGhcArgs' xs' as' fs
getGhcArgs' (x:xs) as fs = getGhcArgs' xs as (x:fs)

0 comments on commit d11cbb2

Please sign in to comment.