diff options
author | Eduardo Julian | 2021-08-11 02:38:59 -0400 |
---|---|---|
committer | Eduardo Julian | 2021-08-11 02:38:59 -0400 |
commit | a62ce3f9c2b605e0033f4772b0f64c4525de4d86 (patch) | |
tree | ecbabe8f110d82b2e6481cf7c0532d4bd4386570 /stdlib/source/library/lux/data/format/json.lux | |
parent | 464b6e8f5e6c62f58fa8c7ff61ab2ad215e98bd1 (diff) |
Relocated maybe and lazy from data to control.
Diffstat (limited to 'stdlib/source/library/lux/data/format/json.lux')
-rw-r--r-- | stdlib/source/library/lux/data/format/json.lux | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/stdlib/source/library/lux/data/format/json.lux b/stdlib/source/library/lux/data/format/json.lux index 5dd7e9c81..5d678fb2c 100644 --- a/stdlib/source/library/lux/data/format/json.lux +++ b/stdlib/source/library/lux/data/format/json.lux @@ -1,6 +1,6 @@ (.module: - {#.doc (.doc "Functionality for reading and writing values in the JSON format." - "For more information, please see: http://www.json.org/")} + {#.doc (.example "Functionality for reading and writing values in the JSON format." + "For more information, please see: http://www.json.org/")} [library [lux #* ["." meta (#+ monad)] @@ -11,19 +11,19 @@ ["." monad (#+ do)]] [control pipe + ["." maybe] ["." try (#+ Try)] ["<>" parser ("#\." monad) ["<.>" text (#+ Parser)]]] [data ["." bit] - ["." maybe] ["." product] ["." text ("#\." equivalence monoid)] [collection ["." list ("#\." fold functor)] ["." row (#+ Row row) ("#\." monad)] ["." dictionary (#+ Dictionary)]]] - [macro (#+ with_gensyms) + [macro [syntax (#+ syntax:)] ["." code]] [math @@ -67,14 +67,14 @@ (|>> (dictionary.of_list text.hash) #..Object)) (syntax: .public (json token) - {#.doc (doc "A simple way to produce JSON literals." - (json #null) - (json #1) - (json +123.456) - (json "this is a string") - (json ["this" "is" "an" "array"]) - (json {"this" "is" - "an" "object"}))} + {#.doc (example "A simple way to produce JSON literals." + (json #null) + (json #1) + (json +123.456) + (json "this is a string") + (json ["this" "is" "an" "array"]) + (json {"this" "is" + "an" "object"}))} (let [(^open ".") ..monad wrapper (function (_ x) (` (..json (~ x))))] (case token @@ -420,4 +420,4 @@ (Codec Text JSON) (def: encode ..format) - (def: decode (<text>.run json_parser))) + (def: decode (<text>.result json_parser))) |