aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/program/aedifex/metadata/artifact.lux
diff options
context:
space:
mode:
authorEduardo Julian2020-12-17 22:03:54 -0400
committerEduardo Julian2020-12-17 22:03:54 -0400
commit68b1dd82f23d6648ac3d9075a8f84b0174392945 (patch)
tree2db148a005c21552947d96dfd4e788ba21705037 /stdlib/source/program/aedifex/metadata/artifact.lux
parentabc5c5293603229b447b8b5dfa7f3275571ad982 (diff)
More optimizations to the Lux syntax parser.
Diffstat (limited to 'stdlib/source/program/aedifex/metadata/artifact.lux')
-rw-r--r--stdlib/source/program/aedifex/metadata/artifact.lux17
1 files changed, 12 insertions, 5 deletions
diff --git a/stdlib/source/program/aedifex/metadata/artifact.lux b/stdlib/source/program/aedifex/metadata/artifact.lux
index 1f8068111..aa7b9abce 100644
--- a/stdlib/source/program/aedifex/metadata/artifact.lux
+++ b/stdlib/source/program/aedifex/metadata/artifact.lux
@@ -61,6 +61,7 @@
[<group> "groupId"]
[<name> "artifactId"]
[<version> "version"]
+ [<versioning> "versioning"]
[<versions> "versions"]
[<last-updated> "lastUpdated"]
[<metadata> "metadata"]
@@ -87,8 +88,10 @@
xml.attributes
(list (..write-group (get@ #group value))
(..write-name (get@ #name value))
- (..write-versions (get@ #versions value))
- (..write-last-updated (get@ #last-updated value)))))
+ (#xml.Node ..<versioning>
+ xml.attributes
+ (list (..write-versions (get@ #versions value))
+ (..write-last-updated (get@ #last-updated value)))))))
(def: (sub tag parser)
(All [a] (-> xml.Tag (Parser a) (Parser a)))
@@ -136,9 +139,13 @@
($_ <>.and
(<xml>.somewhere (..text ..<group>))
(<xml>.somewhere (..text ..<name>))
- (<xml>.somewhere (<| (..sub ..<versions>)
- (<>.many (..text ..<version>))))
- (<xml>.somewhere ..last-updated-parser)
+ (<| (..sub ..<versioning>)
+ ($_ <>.and
+ (<| <xml>.somewhere
+ (..sub ..<versions>)
+ (<>.many (..text ..<version>)))
+ (<xml>.somewhere ..last-updated-parser)
+ ))
)))
(def: #export equivalence