summaryrefslogtreecommitdiff
path: root/src/compiler/SimpleEditor/Convert.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiler/SimpleEditor/Convert.hs')
-rw-r--r--src/compiler/SimpleEditor/Convert.hs9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/compiler/SimpleEditor/Convert.hs b/src/compiler/SimpleEditor/Convert.hs
index e2fc20358..e6cb98124 100644
--- a/src/compiler/SimpleEditor/Convert.hs
+++ b/src/compiler/SimpleEditor/Convert.hs
@@ -24,14 +24,13 @@ import SimpleEditor.JSON
parseModule (path,source) =
- prop path $
+ (path.=) $
case runP pModDef (BS.pack source) of
Left (Pn l c,msg) ->
- makeObj [prop "error" msg,
- prop "location" (show l++":"++show c)]
+ makeObj ["error".=msg, "location".= show l++":"++show c]
Right mod -> case convModule mod of
- Ok g -> makeObj [prop "converted" g]
- Bad msg -> makeObj [prop "parsed" msg]
+ Ok g -> makeObj ["converted".=g]
+ Bad msg -> makeObj ["parsed".=msg]
{-
convAbstractFile path =