[treat nodes with ValUnknowns as if they were holes, print some extra info into generated grin files
John Meacham <john@repetae.net>**20070302233704] hunk ./C/FromGrin.hs 254
-
-isValUnknown ValUnknown {} = True
-isValUnknown _ = False
hunk ./C/FromGrin2.hs 459
-
-isValUnknown ValUnknown {} = True
-isValUnknown _ = False
hunk ./Grin/Grin.hs 42
+    isValUnknown,
hunk ./Grin/Grin.hs 447
+isValUnknown ValUnknown {} = True
+isValUnknown _ = False
+
+
hunk ./Grin/PointsToAnalysis.hs 582
-
-isValUnknown ValUnknown {} = True
-isValUnknown _ = False
hunk ./Grin/Simplify.hs 115
-    gv (NodeC t xs,Return (NodeC t' [])) |  t' == tagHole = do
-            lift $ tick stats at_OptSimplifyHoleAssignment
-            gv (Tup xs, Return $ Tup $ Prelude.map (properHole . getType) xs)
+--    gv (NodeC t xs,Return (NodeC t' [])) |  t' == tagHole = do
+--            lift $ tick stats at_OptSimplifyHoleAssignment
+--            gv (Tup xs, Return $ Tup $ Prelude.map (properHole . getType) xs)
hunk ./Grin/Simplify.hs 168
-    getCS (b@Var {},Store v@(NodeC t _)) | not (isMutableNodeTag t), tagIsWHNF t, t /= tagHole = return $ Map.fromList [(Store v,Return b),(Fetch b,Return v),(App funcEval [b] TyNode,Return v)]
-    getCS (b@Var {},Store v@(NodeC t _)) | not (isMutableNodeTag t), t /= tagHole = return $ Map.fromList [(Store v,Return b)]
+    getCS (b@Var {},Store v@(NodeC t _)) | not (isMutableNodeTag t), tagIsWHNF t, not (isHoly v) = return $ Map.fromList [(Store v,Return b),(Fetch b,Return v),(App funcEval [b] TyNode,Return v)]
+    getCS (b@Var {},Store v@(NodeC t _)) | not (isMutableNodeTag t), not (isHoly v) = return $ Map.fromList [(Store v,Return b)]
hunk ./Grin/Simplify.hs 175
+    isHoly (NodeC _ as) | any isValUnknown as = True
+    isHoly n = isHole n
+
hunk ./Main.hs 9
-import IO(hFlush,stderr,stdout,openFile,hClose,IOMode(..))
+import IO(hFlush,stderr,stdout,openFile,hClose,IOMode(..),hPutStrLn)
hunk ./Main.hs 100
-    pn <- System.getProgName
-    as <- getArguments
-    wdump FD.Html $ putStrLn $ "<html><head><title>" ++ (unwords (pn:as)) ++ "</title><meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\"></head><body style=\"background: black; color: lightgrey\"><pre>"
+    (argstring,_) <- getArgString
+    wdump FD.Html $ putStrLn $ "<html><head><title>" ++ argstring ++ "</title><meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\"></head><body style=\"background: black; color: lightgrey\"><pre>"
hunk ./Main.hs 107
-        name <- System.getProgName
-        args <- getArguments
-        return (simpleQuote (name:args) ++ "\n" ++ versionSimple)
+        (argstring,_) <- getArgString
+        return (argstring ++ "\n" ++ versionSimple)
hunk ./Main.hs 786
+    (argstring,sversion) <- getArgString
+    hPutStrLn h $ unlines [ "-- " ++ argstring,"-- " ++ sversion,""]
hunk ./Main.hs 792
+getArgString = do
+    name <- System.getProgName
+    args <- getArguments
+    return (simpleQuote (name:args),head $ lines versionString)
+
hunk ./Main.hs 805
-    name <- System.getProgName
-    args <- getArguments
-    let argstring = simpleQuote (name:args)
+    (argstring,sversion) <- getArgString
+    let
hunk ./Main.hs 814
-    writeFile cf $ unlines [globalvar "jhc_c_compile" comm, globalvar "jhc_command" argstring,globalvar "jhc_version" (head $ lines versionString),"",cg]
+    writeFile cf $ unlines [globalvar "jhc_c_compile" comm, globalvar "jhc_command" argstring,globalvar "jhc_version" sversion,"",cg]