From 036f3b68983381c6fd2c380f01011ddaf0d8021f Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Mon, 4 Sep 2017 21:16:42 -0400 Subject: - Simplified code for JSON format. - Moved JSON polytypism to the lux/macro/poly/* branch. --- stdlib/test/test/lux/data/format/json.lux | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'stdlib/test') diff --git a/stdlib/test/test/lux/data/format/json.lux b/stdlib/test/test/lux/data/format/json.lux index 2dce7ad84..bd0e4ab67 100644 --- a/stdlib/test/test/lux/data/format/json.lux +++ b/stdlib/test/test/lux/data/format/json.lux @@ -12,9 +12,7 @@ [bool] [maybe] [number "i/" Number] - (format ["@" json] - (json ["@;" reader] - ["@;" codec])) + (format ["@" json]) (coll [vector #+ vector] ["d" dict] [list])) @@ -22,7 +20,8 @@ (macro [code] [syntax #+ syntax:] [poly #+ derived:] - [poly/eq]) + [poly/eq] + [poly/json]) ["r" math/random] test) ) @@ -44,7 +43,7 @@ (context: "JSON" [sample gen-json #let [(^open "@/") @;Eq - (^open "@/") @codec;Codec]] + (^open "@/") @;Codec]] ($_ seq (test "Every JSON is equal to itself." (@/= sample sample)) @@ -104,7 +103,7 @@ gen-recursive ))) -(derived: (@codec;Codec Record)) +(derived: (poly/json;Codec Record)) (struct: _ (Eq Record) (def: (= recL recR) -- cgit v1.2.3