Mike Gerwitz

Activist for User Freedom

aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMike Gerwitz <gerwitm@lovullo.com>2016-07-05 23:57:59 -0400
committerMike Gerwitz <gerwitm@lovullo.com>2016-07-06 00:16:12 -0400
commitb2d87c531837c04df5501d65ad67a56a689f3eb5 (patch)
treeb3b9714ef2f8ffcc9ffe3e3fc501fac46e083024 /src
parente5da6f8ce10f9b7cd5e11ffe7a3ba4302ba6c216 (diff)
downloadtame-b2d87c531837c04df5501d65ad67a56a689f3eb5.tar.gz
tame-b2d87c531837c04df5501d65ad67a56a689f3eb5.tar.bz2
tame-b2d87c531837c04df5501d65ad67a56a689f3eb5.zip
Re-order graph:dep-lookup arguments to favor partial application
* src/graph.xsl (graph:dep-lookup): Re-order arguments * test/graph.xspec: Updated accordingly
Diffstat (limited to 'src')
-rw-r--r--src/graph.xsl10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/graph.xsl b/src/graph.xsl
index 25fdad6..7351cd7 100644
--- a/src/graph.xsl
+++ b/src/graph.xsl
@@ -223,11 +223,13 @@
From a graph perspective,
the dependencies are edges on the @var{$symbol} vertex.
+
+ Parameters are organized for partial application.
-->
<function name="graph:dep-lookup" as="element( preproc:sym-dep )?">
- <param name="symbol" as="element( preproc:sym )" />
- <param name="graph" as="element( preproc:sym-deps )" />
<param name="lookup" />
+ <param name="graph" as="element( preproc:sym-deps )" />
+ <param name="symbol" as="element( preproc:sym )" />
<variable name="deps" as="element( preproc:sym-dep )?"
select="$graph/preproc:sym-dep
@@ -236,9 +238,9 @@
<sequence select="if ( exists( $deps ) ) then
$deps
else if ( $lookup ) then
- graph:dep-lookup( $symbol,
+ graph:dep-lookup( $lookup,
f:apply( $lookup, $symbol ),
- $lookup )
+ $symbol )
else
()" />
</function>