summaryrefslogtreecommitdiff
path: root/src/compiler/GF/Grammar/CanonicalJSON.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiler/GF/Grammar/CanonicalJSON.hs')
-rw-r--r--src/compiler/GF/Grammar/CanonicalJSON.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/compiler/GF/Grammar/CanonicalJSON.hs b/src/compiler/GF/Grammar/CanonicalJSON.hs
index 8024fe99a..8b3464674 100644
--- a/src/compiler/GF/Grammar/CanonicalJSON.hs
+++ b/src/compiler/GF/Grammar/CanonicalJSON.hs
@@ -210,10 +210,10 @@ instance JSON a => JSON (RecordRow a) where
where fromRow (lbl, jsvalue) = do value <- readJSON jsvalue
return (RecordRow (LabelId lbl) value)
-instance JSON TableRowValue where
- showJSON (TableRowValue l v) = makeObj [(".pattern", showJSON l), (".value", showJSON v)]
+instance JSON rhs => JSON (TableRow rhs) where
+ showJSON (TableRow l v) = makeObj [(".pattern", showJSON l), (".value", showJSON v)]
- readJSON o = TableRowValue <$> o!".pattern" <*> o!".value"
+ readJSON o = TableRow <$> o!".pattern" <*> o!".value"
-- *** Identifiers in Concrete Syntax