Compare commits
No commits in common. "279ddc660e42b9828c8f17242e42c4542054e60d" and "09bf0d180786eef1ef0df76d73f5ecaf68488519" have entirely different histories.
279ddc660e
...
09bf0d1807
40
INSTALL
40
INSTALL
|
@ -1,40 +0,0 @@
|
||||||
hoxsl may be used directly from the distribution archive.
|
|
||||||
|
|
||||||
To build from source (including a repository checkout), see `Configuring'
|
|
||||||
below.
|
|
||||||
|
|
||||||
|
|
||||||
Configuring
|
|
||||||
===========
|
|
||||||
If your distribution contains a `configure` file in the project root, you
|
|
||||||
may immediately run `./configure`.
|
|
||||||
|
|
||||||
Otherwise, you likely have the sources as they exist in the project
|
|
||||||
repository, which does not contain the generated `configure` script; you
|
|
||||||
may generate it by issuing the following command:
|
|
||||||
|
|
||||||
$ autoreconf -fvi
|
|
||||||
|
|
||||||
hoxsl has two dependencies, which may be cloned as such:
|
|
||||||
|
|
||||||
$ git clone https://github.com/lovullo/literate-xsl tools/literate-xsl
|
|
||||||
$ git clone https://github.com/lovullo/xspec tools/xspec
|
|
||||||
|
|
||||||
The latter is required only if running test cases (using `make check').
|
|
||||||
Once dependencies are in place, simply run:
|
|
||||||
|
|
||||||
$ ./configure
|
|
||||||
|
|
||||||
|
|
||||||
Building
|
|
||||||
========
|
|
||||||
After running `configure' above, all necessary runtime files and literate
|
|
||||||
documentation may be built by running:
|
|
||||||
|
|
||||||
$ make
|
|
||||||
|
|
||||||
To build the distribution files, run `make distdir`. To create the
|
|
||||||
distribution tarball, run `make dist`.
|
|
||||||
|
|
||||||
To run all tests, run `make check`.
|
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
## hoxsl Makefile
|
## hoxsl Makefile
|
||||||
#
|
#
|
||||||
# Copyright (C) 2016 Mike Gerwitz
|
|
||||||
# Copyright (C) 2014 LoVullo Associates, Inc.
|
# Copyright (C) 2014 LoVullo Associates, Inc.
|
||||||
#
|
#
|
||||||
# This program is free software: you can redistribute it and/or modify
|
# This program is free software: you can redistribute it and/or modify
|
||||||
|
@ -18,7 +17,6 @@
|
||||||
##
|
##
|
||||||
|
|
||||||
SUBDIRS = doc
|
SUBDIRS = doc
|
||||||
EXTRA_DIST = INSTALL COPYING.FDL README.md src test doc/macros.texi
|
|
||||||
|
|
||||||
path_src := src
|
path_src := src
|
||||||
path_test := test
|
path_test := test
|
||||||
|
@ -37,6 +35,3 @@ check: $(test_apply)
|
||||||
$(JAVA) -jar "$(SAXON_CP)" \
|
$(JAVA) -jar "$(SAXON_CP)" \
|
||||||
-xsl:"$(path_src)/transform/apply-gen.xsl" \
|
-xsl:"$(path_src)/transform/apply-gen.xsl" \
|
||||||
"$<" > "$@"
|
"$<" > "$@"
|
||||||
|
|
||||||
clean-local:
|
|
||||||
$(RM) $(test_apply)
|
|
||||||
|
|
11
README.md
11
README.md
|
@ -11,12 +11,13 @@
|
||||||
-->
|
-->
|
||||||
# Higher-Order XSLT
|
# Higher-Order XSLT
|
||||||
hoxsl is a library for XSLT 2.0, written in pure XSLT, introducing
|
hoxsl is a library for XSLT 2.0, written in pure XSLT, introducing
|
||||||
various higher-order operations; this includes higher-order functions and
|
various types of higher-order logic; this includes higher-order
|
||||||
XSLT templates that take XSLT as input and produce XSLT as output.
|
functions and XSLT templates that take XSLT as input and produce XSLT
|
||||||
|
as output.
|
||||||
|
|
||||||
The system is fully tested---see the test cases for additional
|
The system is fully tested---see the test cases for additional
|
||||||
documentation as this project gets under way. The manual is "woven" from
|
documentation as this project gets under way. This README will serve
|
||||||
literate sources; [a compiled version is available online][manual].
|
as an informal manual until official documentation is produced.
|
||||||
|
|
||||||
|
|
||||||
## Higher-Order Functions
|
## Higher-Order Functions
|
||||||
|
@ -113,5 +114,3 @@ PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
||||||
|
|
||||||
[nova-ho]: http://conferences.idealliance.org/extreme/html/2006/Novatchev01/EML2006Novatchev01.html
|
[nova-ho]: http://conferences.idealliance.org/extreme/html/2006/Novatchev01/EML2006Novatchev01.html
|
||||||
[xslt-30-ho]: http://www.w3.org/TR/xslt-30/#dt-higher-order-operand
|
[xslt-30-ho]: http://www.w3.org/TR/xslt-30/#dt-higher-order-operand
|
||||||
[manual]: https://mikegerwitz.com/hoxsl/manual/
|
|
||||||
|
|
||||||
|
|
|
@ -11,8 +11,8 @@
|
||||||
@copying
|
@copying
|
||||||
This manual is for hoxsl, version @value{VERSION}.
|
This manual is for hoxsl, version @value{VERSION}.
|
||||||
|
|
||||||
Copyright @copyright{} 2015, 2016 Mike Gerwitz
|
|
||||||
Copyright @copyright{} 2014, 2015 LoVullo Associates, Inc.
|
Copyright @copyright{} 2014, 2015 LoVullo Associates, Inc.
|
||||||
|
Copyright @copyright{} 2015 Mike Gerwitz
|
||||||
|
|
||||||
@quotation
|
@quotation
|
||||||
Permission is granted to copy, distribute and/or modify this document
|
Permission is granted to copy, distribute and/or modify this document
|
||||||
|
|
|
@ -62,11 +62,7 @@
|
||||||
<text>hoxsl; please do not modify</text>
|
<text>hoxsl; please do not modify</text>
|
||||||
</comment>
|
</comment>
|
||||||
|
|
||||||
<out:stylesheet version="{( @version, '2.0' )[ 1 ]}">
|
<out:stylesheet version="2.0">
|
||||||
<!-- namespaces might be referenced in strings (e.g. @as), and so may
|
|
||||||
not be copied by default -->
|
|
||||||
<sequence select="namespace::*[ name() ]" />
|
|
||||||
|
|
||||||
<xsl:apply-templates mode="fgen:create" />
|
<xsl:apply-templates mode="fgen:create" />
|
||||||
</out:stylesheet>
|
</out:stylesheet>
|
||||||
</document>
|
</document>
|
||||||
|
|
|
@ -40,46 +40,6 @@
|
||||||
</variable>
|
</variable>
|
||||||
|
|
||||||
|
|
||||||
<!-- while functions are only supported in version >=2, this could be run
|
|
||||||
on future versions, and we want to make sure that we don't break
|
|
||||||
anything -->
|
|
||||||
<scenario label="stylesheet version">
|
|
||||||
<scenario label="when provided">
|
|
||||||
<context>
|
|
||||||
<xsl:stylesheet version="7.05" />
|
|
||||||
</context>
|
|
||||||
|
|
||||||
<expect label="is copied to output"
|
|
||||||
test="xsl:stylesheet/@version = '7.05'" />
|
|
||||||
</scenario>
|
|
||||||
|
|
||||||
|
|
||||||
<scenario label="when empty">
|
|
||||||
<context>
|
|
||||||
<xsl:stylesheet />
|
|
||||||
</context>
|
|
||||||
|
|
||||||
<expect label="defaults to 2.0"
|
|
||||||
test="xsl:stylesheet/@version = '2.0'" />
|
|
||||||
</scenario>
|
|
||||||
</scenario>
|
|
||||||
|
|
||||||
|
|
||||||
<!-- source namespaces must be copied -->
|
|
||||||
<scenario label="source namespaces">
|
|
||||||
<context>
|
|
||||||
<xsl:stylesheet xmlns:foobar="baz">
|
|
||||||
<xsl:function name="foobar:baz">
|
|
||||||
<xsl:param name="foo" />
|
|
||||||
</xsl:function>
|
|
||||||
</xsl:stylesheet>
|
|
||||||
</context>
|
|
||||||
|
|
||||||
<expect label="are copied to destination"
|
|
||||||
test="exists( xsl:stylesheet/namespace::foobar )" />
|
|
||||||
</scenario>
|
|
||||||
|
|
||||||
|
|
||||||
<!-- basic case -->
|
<!-- basic case -->
|
||||||
<scenario label="given a unary function">
|
<scenario label="given a unary function">
|
||||||
<context>
|
<context>
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
Subproject commit 5cded3d64bec3c0c2b42b67169aa27cf5810bc50
|
|
@ -1 +1 @@
|
||||||
Subproject commit fcd852b0482d0a61d016867b5bfd463f7193f0cb
|
Subproject commit 20c6b8a32f37a6511698fe89b78b82fd1aa64bd2
|
Loading…
Reference in New Issue