Commit 220f0ae7 authored by krasimir's avatar krasimir

[project @ 2005-01-23 09:41:01 by krasimir]

Use withProgName. Without it getProgName from the executed script will return
"<interactive>"
parent 6f985ae8
......@@ -45,9 +45,9 @@ main = do
dieProg "syntax: runghc [-f GHCPATH] FILE ARG..."
doIt ghc filename args = do
res <- rawSystem ghc ["-e","System.Environment.withArgs ["
res <- rawSystem ghc ["-e","System.Environment.withProgName "++show filename++" (System.Environment.withArgs ["
++ concat (intersperse "," (map show args))
++ "] Main.main", filename]
++ "] Main.main)", filename]
exitWith res
dieProg :: String -> IO a
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment