Merge remote-tracking branch 'origin/2.3-gae'

Project: http://git-wip-us.apache.org/repos/asf/incubator-freemarker/repo
Commit: 
http://git-wip-us.apache.org/repos/asf/incubator-freemarker/commit/c6209680
Tree: http://git-wip-us.apache.org/repos/asf/incubator-freemarker/tree/c6209680
Diff: http://git-wip-us.apache.org/repos/asf/incubator-freemarker/diff/c6209680

Branch: refs/heads/master
Commit: c62096801d5b02fc5e2404871e52aee0249b5f0d
Parents: e8fdf53 64f2cd1
Author: ddekany <ddek...@apache.org>
Authored: Sat Jan 2 01:44:27 2016 +0100
Committer: ddekany <ddek...@apache.org>
Committed: Sat Jan 2 01:46:42 2016 +0100

----------------------------------------------------------------------
 NOTICE                                          |   2 +-
 README                                          | 134 ++++++++++
 README.txt                                      | 113 --------
 RELEASE-NOTES                                   |   6 +
 build.xml                                       | 128 ++++++---
 codestyle.xml                                   |  18 ++
 src/dist/DISCLAIMER                             |   8 -
 src/dist/LICENSE                                | 257 -------------------
 src/dist/NOTICE                                 |  30 ---
 src/dist/bin/LICENSE                            | 257 +++++++++++++++++++
 src/dist/bin/NOTICE                             |  30 +++
 src/dist/bin/documentation/index.html           |  65 +++++
 src/dist/documentation/index.html               |  98 -------
 src/examples/README.txt                         |  19 ++
 src/examples/ant/README.txt                     |  19 ++
 .../freemarker/ext/beans/UnsafeMethods.java     |   2 +-
 .../freemarker/template/utility/StringUtil.java |   2 +-
 src/main/misc/overloadedNumberRules/README.txt  |  19 ++
 src/main/misc/overloadedNumberRules/prices.csv  |  48 ----
 .../ext/beans/unsafeMethods.properties          |  98 +++++++
 .../freemarker/ext/beans/unsafeMethods.txt      |  81 ------
 src/manual/change-log-2.4.txt                   |  19 ++
 src/manual/en_US/docgen-help/editors-readme.txt |  19 ++
 .../en_US/docgen-misc/copyrightComment.txt      |  16 ++
 .../figures/odg-convert-howto.txt               |  19 ++
 src/manual/en_US/docgen.cjson                   |   5 +-
 src/manual/zh_CN/placeholder.txt                |  19 ++
 src/test/java/freemarker/core/ASTTest.java      |   6 +-
 .../java/freemarker/core/CanonicalFormTest.java |  11 +-
 .../CopyrightCommentRemoverTemplateLoader.java  |   2 +-
 src/test/java/freemarker/test/TemplateTest.java |   2 +-
 src/test/java/freemarker/test/TestUtil.java     |  36 ++-
 .../freemarker/test/servlet/WebAppTestCase.java |   3 +-
 .../freemarker/test/utility/FileTestCase.java   |   3 +-
 src/test/resources/freemarker/core/ast-1.ast    |  18 ++
 .../freemarker/core/ast-assignments.ast         |  18 ++
 .../resources/freemarker/core/ast-builtins.ast  |  18 ++
 .../resources/freemarker/core/ast-locations.ast |  18 ++
 .../core/ast-mixedcontentsimplifications.ast    |  18 ++
 .../core/ast-multipleignoredchildren.ast        |  18 ++
 .../core/ast-nestedignoredchildren.ast          |  18 ++
 .../resources/freemarker/core/ast-range.ast     |  18 ++
 .../freemarker/core/ast-strlitinterpolation.ast |  18 ++
 .../freemarker/core/ast-whitespacestripping.ast |  18 ++
 .../core/cano-assignments-canonical.ftl         |  34 ---
 .../freemarker/core/cano-assignments.ftl.out    |  34 +++
 .../freemarker/core/cano-builtins-canonical.ftl |  22 --
 .../freemarker/core/cano-builtins.ftl.out       |  23 ++
 .../core/cano-identifier-escaping-canonical.ftl |  43 ----
 .../core/cano-identifier-escaping.ftl.out       |  44 ++++
 .../freemarker/core/cano-macros-canonical.ftl   |  28 --
 .../freemarker/core/cano-macros.ftl.out         |  28 ++
 .../core/cano-strlitinterpolation-canonical.ftl |  18 --
 .../core/cano-strlitinterpolation.ftl.out       |  19 ++
 .../basic/WEB-INF/expected/attributes-2.3.0.txt |  18 ++
 .../expected/attributes-2.3.22-future.txt       |  18 ++
 .../basic/WEB-INF/expected/attributes.txt       |  18 ++
 .../basic/WEB-INF/expected/customTags1.txt      |  18 ++
 .../webapps/config/WEB-INF/lib/templates.jar    | Bin 579 -> 1018 bytes
 .../WEB-INF/expected/subdir/test-rel.txt        |  18 ++
 .../WEB-INF/expected/test-noClasspath.txt       |  18 ++
 .../tldDiscovery/WEB-INF/expected/test1.txt     |  18 ++
 .../tldDiscovery/WEB-INF/lib/taglib-foo.jar     | Bin 791 -> 1221 bytes
 .../webapps/tldDiscovery/WEB-INF/taglib 2.jar   | Bin 752 -> 1179 bytes
 .../manual/AutoEscapingExample-capture.ftlh.out |  18 ++
 .../manual/AutoEscapingExample-convert.ftlh.out |  18 ++
 .../manual/AutoEscapingExample-convert2.ftl.out |  18 ++
 .../manual/AutoEscapingExample-infoBox.ftlh.out |  18 ++
 .../manual/AutoEscapingExample-markup.ftlh.out  |  18 ++
 .../AutoEscapingExample-stringConcat.ftlh.out   |  18 ++
 .../AutoEscapingExample-stringLiteral.ftlh.out  |  18 ++
 .../AutoEscapingExample-stringLiteral2.ftlh.out |  18 ++
 .../manual/CustomFormatsExample-alias1.ftlh.out |  18 ++
 .../manual/CustomFormatsExample-alias2.ftlh.out |  18 ++
 .../CustomFormatsExample-modelAware.ftlh.out    |  18 ++
 .../test/templatesuite/expected/arithmetic.txt  |  18 ++
 .../test/templatesuite/expected/bean-maps.txt   |  18 ++
 .../test/templatesuite/expected/beans.txt       |  18 ++
 .../expected/boolean-formatting.txt             |  18 ++
 .../test/templatesuite/expected/boolean.txt     |  18 ++
 .../expected/charset-in-header.txt              |  18 ++
 .../expected/classic-compatible.txt             |  18 ++
 .../test/templatesuite/expected/comment.txt     |  18 ++
 .../test/templatesuite/expected/comparisons.txt |  18 ++
 .../test/templatesuite/expected/compress.txt    |  18 ++
 .../templatesuite/expected/dateformat-java.txt  |  18 ++
 .../templatesuite/expected/default-xmlns.txt    |  18 ++
 .../test/templatesuite/expected/default.txt     |  18 ++
 .../expected/encoding-builtins-ici-2.3.20.txt   |  18 ++
 .../expected/encoding-builtins.txt              |  18 ++
 .../test/templatesuite/expected/escapes.txt     |  18 ++
 .../test/templatesuite/expected/exception.txt   |  18 ++
 .../test/templatesuite/expected/exception2.txt  |  18 ++
 .../test/templatesuite/expected/exception3.txt  |  18 ++
 .../test/templatesuite/expected/exthash.txt     |  18 ++
 .../test/templatesuite/expected/hashconcat.txt  |  18 ++
 .../test/templatesuite/expected/hashliteral.txt |  18 ++
 .../test/templatesuite/expected/helloworld.txt  |  18 ++
 .../expected/identifier-escaping.txt            |  18 ++
 .../expected/identifier-non-ascii.txt           |  18 ++
 .../test/templatesuite/expected/if.txt          |  18 ++
 .../test/templatesuite/expected/import.txt      |  18 ++
 .../test/templatesuite/expected/include.txt     |  18 ++
 .../test/templatesuite/expected/include2.txt    |  18 ++
 .../test/templatesuite/expected/interpret.txt   |  18 ++
 .../test/templatesuite/expected/iterators.txt   |  18 ++
 .../templatesuite/expected/lastcharacter.txt    |  18 ++
 .../test/templatesuite/expected/list-bis.txt    |  18 ++
 .../test/templatesuite/expected/list.txt        |  18 ++
 .../test/templatesuite/expected/list2.txt       |  18 ++
 .../test/templatesuite/expected/list3.txt       |  18 ++
 .../test/templatesuite/expected/listliteral.txt |  18 ++
 .../templatesuite/expected/localization.txt     |  18 ++
 .../test/templatesuite/expected/logging.txt     |  18 ++
 .../templatesuite/expected/loopvariable.txt     |  18 ++
 .../templatesuite/expected/macros-return.txt    |  18 ++
 .../test/templatesuite/expected/macros.txt      |  18 ++
 .../test/templatesuite/expected/macros2.txt     |  18 ++
 .../test/templatesuite/expected/multimodels.txt |  18 ++
 .../test/templatesuite/expected/nested.txt      |  18 ++
 .../expected/new-allowsnothing.txt              |  18 ++
 .../expected/new-defaultresolver.txt            |  18 ++
 .../test/templatesuite/expected/new-optin.txt   |  18 ++
 .../test/templatesuite/expected/new-safer.txt   |  18 ++
 .../templatesuite/expected/new-unrestricted.txt |  18 ++
 .../test/templatesuite/expected/newlines1.txt   |  18 ++
 .../test/templatesuite/expected/newlines2.txt   |  18 ++
 .../expected/non-strict-syntax.txt              |  18 ++
 .../test/templatesuite/expected/noparse.txt     |  18 ++
 .../templatesuite/expected/number-format.txt    |  18 ++
 .../templatesuite/expected/number-literal.txt   |  18 ++
 .../templatesuite/expected/number-to-date.txt   |  18 ++
 .../templatesuite/expected/numerical-cast.txt   |  18 ++
 .../templatesuite/expected/output-encoding1.txt |  18 ++
 .../templatesuite/expected/output-encoding2.txt | Bin 356 -> 1976 bytes
 .../templatesuite/expected/output-encoding3.txt |  18 ++
 .../test/templatesuite/expected/precedence.txt  |  18 ++
 .../test/templatesuite/expected/recover.txt     |  18 ++
 .../test/templatesuite/expected/root.txt        |  18 ++
 .../expected/sequence-builtins.txt              |  18 ++
 .../test/templatesuite/expected/specialvars.txt |  18 ++
 .../templatesuite/expected/strictinheader.txt   |  18 ++
 .../string-builtins-regexps-matches.txt         |  18 ++
 .../expected/string-builtins-regexps.txt        |  18 ++
 .../templatesuite/expected/string-builtins1.txt |  18 ++
 .../templatesuite/expected/string-builtins2.txt |  18 ++
 .../templatesuite/expected/stringbimethods.txt  |  18 ++
 .../templatesuite/expected/stringliteral.txt    | Bin 740 -> 1552 bytes
 .../test/templatesuite/expected/switch.txt      |  18 ++
 .../test/templatesuite/expected/transforms.txt  |  18 ++
 .../expected/type-builtins-ici-2.3.21.txt       |  18 ++
 .../expected/type-builtins-ici-2.3.24.txt       |  18 ++
 .../templatesuite/expected/type-builtins.txt    |  18 ++
 .../test/templatesuite/expected/var-layers.txt  |  18 ++
 .../test/templatesuite/expected/varargs.txt     |  18 ++
 .../test/templatesuite/expected/variables.txt   |  18 ++
 .../templatesuite/expected/whitespace-trim.txt  |  18 ++
 .../templatesuite/expected/wstrip-in-header.txt |  18 ++
 .../test/templatesuite/expected/wstripping.txt  |  18 ++
 .../templatesuite/expected/xml-fragment.txt     |  18 ++
 .../expected/xml-ns_prefix-scope.txt            |  18 ++
 .../test/templatesuite/expected/xml.txt         |  18 ++
 .../test/templatesuite/expected/xmlns1.txt      |  18 ++
 .../test/templatesuite/expected/xmlns3.txt      |  18 ++
 .../test/templatesuite/expected/xmlns4.txt      |  18 ++
 .../test/templatesuite/expected/xmlns5.txt      |  18 ++
 166 files changed, 3165 insertions(+), 828 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-freemarker/blob/c6209680/build.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-freemarker/blob/c6209680/src/main/java/freemarker/template/utility/StringUtil.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-freemarker/blob/c6209680/src/manual/change-log-2.4.txt
----------------------------------------------------------------------
diff --cc src/manual/change-log-2.4.txt
index 0f85bdc,0000000..1f58955
mode 100644,000000..100644
--- a/src/manual/change-log-2.4.txt
+++ b/src/manual/change-log-2.4.txt
@@@ -1,46 -1,0 +1,65 @@@
++/*
++ * Licensed to the Apache Software Foundation (ASF) under one
++ * or more contributor license agreements.  See the NOTICE file
++ * distributed with this work for additional information
++ * regarding copyright ownership.  The ASF licenses this file
++ * to you under the Apache License, Version 2.0 (the
++ * "License"); you may not use this file except in compliance
++ * with the License.  You may obtain a copy of the License at
++ * 
++ *   http://www.apache.org/licenses/LICENSE-2.0
++ * 
++ * Unless required by applicable law or agreed to in writing,
++ * software distributed under the License is distributed on an
++ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
++ * KIND, either express or implied.  See the License for the
++ * specific language governing permissions and limitations
++ * under the License.
++ */
++
 +This is the (draft) of the 2.4.0 change log so far. It's not in the Manual 
yet, as merging in XDocBook XML
 +changes from the 2.3 branch would be rather difficult.
 +
 +Non-backward compatible (all are unlikely to affect real world applications):
 +- Removed command-line tools (main methods in a library, often classified as 
CWE-489 "Leftover Debug Code"):
 +  - freemarker.core.CommandLine (jar main-class). This has only printed the 
current version and copyright.
 +  - freemarker.ext.dom.Transform. This was used to transform an XML file to 
output file via a template file.
 +    Surpassed by FMPP long ago. (If there will be demand for it, it can be 
still reintroduced in a separate jar.)
 +  - freemarker.template.utility.ToCanonical class: Converted a template to 
its canonical form. As the canonical
 +    form was heavily broken before 2.3.21, and is still not perfect, yet 
nobody has complained, it's assumed
 +    that canonicalization isn't used, hence nor the CLI to it.
 +  - freemarker.ext.jdom.NodeListModel.main() method: Was used to transform an 
XML given on stdin with the specified
 +    template file and write the output to stdout. The data model used for 
this transformation (JDOM NodeListModel) was
 +    deprecated long ago.
 +- Removed TemplateObject.getTemplate(), added getUnboundTemplate() instead. 
TemplateObject is not to be confused with
 +  Template, and is only exploited by very few for some deeper tricks. 
Although TemplateObject is technically
 +  (historically) public, it was marked as internal API and was excluded from 
the JavaDoc for a while.
 +- When TemplateCache2 will be merged in: In 2.3.x, a cached error was thrown 
as a plain IOException with the original
 +  (cached) exception as its cause exception.
 +  This is not possible starting from 2.4.x, because to prevent memory leaks, 
the cache doesn't hold reference to the
 +  cached exception any more, instead it only stores a String description of 
it (class name, message, and the same for
 +  each its cause exceptions). The cached error will be throw as a 
CachedTemplateLoadingException (an IOException
 +  subclass), which contains the string description of the original exception 
in its getMessage() value.
 +- Removed deprecated *package visible* method:
 +  Template#Template(String name, TemplateElement root, Configuration cfg)
 +- freemarker.core.FMParser API changes. These were marked as internal and 
deprecated for a while,
 +  and are very unlikely to be used. They could be exploited for tools that 
try to tokenize String-s as FTL or such.
 +  - freemarker.core.FMParser constructors were removed or has become 
non-public
 +  - freemarker.core.FMParser.createExpressionParser war removed
 +
 +New features:
 +- There are no separate org.freemarker:freemarker-gae and 
org.freemarker:freemarker artifacts any more.
 +  There's only org.freemarker:freemarker, which is GAE compatible.
 +- TemplateLoader.getLastModified(Object templateSource) can now throw 
GetLastModifiedException to indicate an
 +  error instead of returning -1 (which doesn't count as an error).
 +- Custom attributes now keep the order of adding them
 +- Bug fixed: When the same template was both #include-d and #import-ed, the 
macros from the #import-ed template has
 +  ran in the namespace of the #import-ed template.
 +
 +Notes on internal changes (some of this need not be in Version History):
 +- The main change is splitting Template to Template and UnboundTemplate. With 
an analogy, if UnboundTemplate is
 +  the class of the template, then Template is the instance of the template. 
The content of UnboundTemplate only
 +  depends on the content of the actual template file, the ParserSettings, and 
on its *source* path, while Template
 +  contains all the settings defined in by the Configurable class and the name 
with which the template was requested.
 +  This splitting allows more efficient caching when due to the template 
lookup mechanism, multiple Template-s
 +  share the same actual template file.

http://git-wip-us.apache.org/repos/asf/incubator-freemarker/blob/c6209680/src/test/resources/freemarker/core/ast-1.ast
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-freemarker/blob/c6209680/src/test/resources/freemarker/core/ast-assignments.ast
----------------------------------------------------------------------

Reply via email to