diff options
author | Eduardo Julian | 2022-12-02 19:33:00 -0400 |
---|---|---|
committer | Eduardo Julian | 2022-12-02 19:33:00 -0400 |
commit | 94e5802f594a73245fce0fbd885103b8bf210d57 (patch) | |
tree | 65e5799c0be40f5f015b39bfa6c87c9c27fd9424 /stdlib/source/format | |
parent | b491dfff00219d5206075ea65468e00ab657075d (diff) |
Added some simple time-series handling machinery.
Diffstat (limited to 'stdlib/source/format')
-rw-r--r-- | stdlib/source/format/lux/data/binary.lux | 6 | ||||
-rw-r--r-- | stdlib/source/format/lux/data/text.lux | 34 |
2 files changed, 20 insertions, 20 deletions
diff --git a/stdlib/source/format/lux/data/binary.lux b/stdlib/source/format/lux/data/binary.lux index c04c5116b..2014fc99c 100644 --- a/stdlib/source/format/lux/data/binary.lux +++ b/stdlib/source/format/lux/data/binary.lux @@ -113,7 +113,7 @@ (def .public (and pre post) (All (_ a b) (-> (Format a) (Format b) (Format [a b]))) (function (_ [preV postV]) - (at ..monoid composite (pre preV) (post postV)))) + (of ..monoid composite (pre preV) (post postV)))) (def .public (rec body) (All (_ a) (-> (-> (Format a) (Format a)) (Format a))) @@ -175,7 +175,7 @@ (with_template [<name> <binary>] [(def .public <name> (Format Text) - (|>> (at utf8.codec encoded) <binary>))] + (|>> (of utf8.codec encoded) <binary>))] [utf8_8 ..binary_8] [utf8_16 ..binary_16] @@ -198,7 +198,7 @@ (open "specification#[0]") ..monoid [size mutation] (|> value (sequence#each valueW) - (at sequence.mix mix + (of sequence.mix mix (function (_ post pre) (specification#composite pre post)) specification#identity))] diff --git a/stdlib/source/format/lux/data/text.lux b/stdlib/source/format/lux/data/text.lux index db6aa5d7a..532edba75 100644 --- a/stdlib/source/format/lux/data/text.lux +++ b/stdlib/source/format/lux/data/text.lux @@ -58,35 +58,35 @@ (Format <type>) <formatter>)] - [bit Bit (at bit.codec encoded)] - [nat Nat (at nat.decimal encoded)] - [int Int (at int.decimal encoded)] - [rev Rev (at rev.decimal encoded)] - [frac Frac (at frac.decimal encoded)] + [bit Bit (of bit.codec encoded)] + [nat Nat (of nat.decimal encoded)] + [int Int (of int.decimal encoded)] + [rev Rev (of rev.decimal encoded)] + [frac Frac (of frac.decimal encoded)] [text Text text.format] - [ratio ratio.Ratio (at ratio.codec encoded)] - [symbol Symbol (at symbol.codec encoded)] + [ratio ratio.Ratio (of ratio.codec encoded)] + [symbol Symbol (of symbol.codec encoded)] [location Location location.format] [code Code code.format] [type Type type.format] - [instant instant.Instant (at instant.codec encoded)] - [duration duration.Duration (at duration.codec encoded)] - [date date.Date (at date.codec encoded)] - [time time.Time (at time.codec encoded)] - [day day.Day (at day.codec encoded)] - [month month.Month (at month.codec encoded)] + [instant instant.Instant (of instant.codec encoded)] + [duration duration.Duration (of duration.codec encoded)] + [date date.Date (of date.codec encoded)] + [time time.Time (of time.codec encoded)] + [day day.Day (of day.codec encoded)] + [month month.Month (of month.codec encoded)] - [xml xml.XML (at xml.codec encoded)] - [json json.JSON (at json.codec encoded)] + [xml xml.XML (of xml.codec encoded)] + [json json.JSON (of json.codec encoded)] ) (with_template [<type> <format>,<codec>] [(`` (with_template [<format> <codec>] [(def .public <format> (Format <type>) - (at <codec> encoded))] + (of <codec> encoded))] (,, (template.spliced <format>,<codec>))))] @@ -115,7 +115,7 @@ (def .public (mod modular) (All (_ m) (Format (modular.Mod m))) (let [codec (modular.codec (modular.modulus modular))] - (at codec encoded modular))) + (of codec encoded modular))) (def .public (list formatter) (All (_ a) (-> (Format a) (Format (List a)))) |