From 6ebc3f5e3ac2abf6e09a2a6705c05be85fa33179 Mon Sep 17 00:00:00 2001 From: "Niels G. W. Serup" Date: Tue, 24 Sep 2024 22:24:06 +0200 Subject: [PATCH] Change RunPandoc to be more file-centric --- byg/src/DependencyGenerator.hs | 2 +- byg/src/Evaluation/FunctionIO.hs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/byg/src/DependencyGenerator.hs b/byg/src/DependencyGenerator.hs index fea48b9..f32e38a 100644 --- a/byg/src/DependencyGenerator.hs +++ b/byg/src/DependencyGenerator.hs @@ -110,5 +110,5 @@ convertImage = runFunctionIO ConvertImage saveFile :: Token (String, FilePath) -> DepGenM () saveFile = runFunctionIO SaveFile -runPandoc :: Token String -> DepGenM String +runPandoc :: Token (FilePath, FilePath) -> DepGenM () runPandoc = runFunctionIO RunPandoc diff --git a/byg/src/Evaluation/FunctionIO.hs b/byg/src/Evaluation/FunctionIO.hs index 9957c86..d285c58 100644 --- a/byg/src/Evaluation/FunctionIO.hs +++ b/byg/src/Evaluation/FunctionIO.hs @@ -18,8 +18,8 @@ evalFunctionIO f x = case (f, x) of (SaveFile, Tuple (String _, String _)) -> pure $ Empty - (RunPandoc, String _) -> - pure $ String undefined + (RunPandoc, Tuple (String _, String _)) -> + pure $ Empty _ -> error "unexpected combination of function and argument type"