CurryInfo: benchmark-papers-3.0.0 / ExecuteBenchmarkPaper.genMacroFile

definition: Info
 
genMacroFile :: [(String,IO String)] -> String -> IO ()
genMacroFile macros outfile = do
  s <- mapM showMacro macros
  writeFile outfile ("\\newcommand{\\curryresult}[1]\n" ++ genResultMacro s ++ "\n")
  putStrLn $ "Execution results written into file '" ++ outfile ++ "'"
 where
  showMacro (m,act) = do
    bmReport m
    s <- act
    return ("\\ifthenelse{\\equal{#1}{"  ++ m ++ "}}{" ++ s ++ "}\n")

  genResultMacro [] = "{\\{\\texttt{#1}\\}}\n"
  genResultMacro (t:ts) = "{" ++ t ++ "{" ++ genResultMacro ts ++ "}}"
demand: Info
 no demanded arguments
deterministic: Info
 deterministic operation
documentation: Info
 
Generate a LaTeX file containing results of macro execution.
failfree: Info
 (_, _)
indeterministic: Info
 referentially transparent operation
infix: Info
 no fixity defined
iotype: Info
 {(_,_) |-> _}
name: Info
 genMacroFile
precedence: Info
 no precedence defined
result-values: Info
 _
signature: Info
 [(String, Prelude.IO String)] -> String -> Prelude.IO ()
solution-complete: Info
 operation might suspend on free variables
terminating: Info
 possibly non-terminating
totally-defined: Info
 reducible on all ground data terms