From bb9107c8c1634353f3c2633467bbd4a1d52d1ff9 Mon Sep 17 00:00:00 2001 From: Mike Gerwitz Date: Tue, 2 Dec 2014 16:04:34 -0500 Subject: [PATCH] `apply-gen' now generates functions for partial applications This is intended as a convenient shorthand: ```xml ``` --- src/transform/apply-gen.xsl | 112 +++++++++++--- test/transform/apply-gen-test-in.xsl | 15 ++ test/transform/apply-gen.xspec | 212 +++++++++++++++++++++++++++ 3 files changed, 315 insertions(+), 24 deletions(-) diff --git a/src/transform/apply-gen.xsl b/src/transform/apply-gen.xsl index adf5401..c194593 100644 --- a/src/transform/apply-gen.xsl +++ b/src/transform/apply-gen.xsl @@ -32,6 +32,7 @@ xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:f="http://www.lovullo.com/hoxsl/apply" + xmlns:_f="http://www.lovullo.com/hoxsl/apply/_priv" xmlns:fgen="http://www.lovullo.com/hoxsl/apply/gen" xmlns:out="http://www.lovullo.com/hoxsl/apply/gen/_out" exclude-result-prefixes="#default fgen"> @@ -147,10 +148,15 @@ @@ -161,15 +167,42 @@ + + + + + - - + + + + + + + + + + + + + + + + + @@ -187,7 +220,7 @@ - - - + - - - - - - - - - , - - $arg - - - + + + + + + + + + + + + + + + + + + + + + + + + , + + $arg + + + + + + + + diff --git a/test/transform/apply-gen-test-in.xsl b/test/transform/apply-gen-test-in.xsl index 72a64af..631ee0a 100644 --- a/test/transform/apply-gen-test-in.xsl +++ b/test/transform/apply-gen-test-in.xsl @@ -41,4 +41,19 @@ + + + + + + + + + + + + + + diff --git a/test/transform/apply-gen.xspec b/test/transform/apply-gen.xspec index 151731c..ad8dfca 100644 --- a/test/transform/apply-gen.xspec +++ b/test/transform/apply-gen.xspec @@ -26,6 +26,20 @@ xmlns:foo="http://www.lovullo.com/_junk" stylesheet="apply-gen-test.xsl"> + + + + + + + + + + + + + + @@ -218,5 +232,203 @@ select="2" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +