diff options
Diffstat (limited to 'stdlib/source/lux/target/jvm/method.lux')
-rw-r--r-- | stdlib/source/lux/target/jvm/method.lux | 32 |
1 files changed, 14 insertions, 18 deletions
diff --git a/stdlib/source/lux/target/jvm/method.lux b/stdlib/source/lux/target/jvm/method.lux index aab21db0d..c59bf7d58 100644 --- a/stdlib/source/lux/target/jvm/method.lux +++ b/stdlib/source/lux/target/jvm/method.lux @@ -12,7 +12,7 @@ [number (#+) [i64 (#+)]] [format - [".F" binary (#+ Writer Format) ("#@." monoid)]] + [".F" binary (#+ Writer) ("#@." monoid)]] [collection ["." row (#+ Row)]]] [type @@ -54,26 +54,22 @@ //index.equivalence (row.equivalence //attribute.equivalence))) -(def: #export (reader pool) +(def: #export (parser pool) (-> Pool (Parser Method)) ($_ <>.and - (get@ #binaryF.reader modifier.format) - (get@ #binaryF.reader //index.format) - (get@ #binaryF.reader //index.format) - (<2>.row/16 (//attribute.reader pool)))) + modifier.parser + //index.parser + //index.parser + (<2>.row/16 (//attribute.parser pool)))) (def: #export (writer field) (Writer Method) - (let [attribute-format (: (Format Attribute) - {## TODO: Get rid of this dirty hack ASAP - #binaryF.reader (<>.fail "") - #binaryF.writer //attribute.writer})] - (`` ($_ binaryF@compose - (~~ (template [<format> <slot>] - [((get@ #binaryF.writer <format>) (get@ <slot> field))] + (`` ($_ binaryF@compose + (~~ (template [<writer> <slot>] + [(<writer> (get@ <slot> field))] - [modifier.format #modifier] - [//index.format #name] - [//index.format #descriptor] - [(binaryF.row/16 attribute-format) #attributes])) - )))) + [modifier.writer #modifier] + [//index.writer #name] + [//index.writer #descriptor] + [(binaryF.row/16 //attribute.writer) #attributes])) + ))) |