Commit Graph

7732 Commits

Author SHA1 Message Date
Fabien Potencier 61d45b3e24 feature #1753 added a base node visitor to make compat between 1.x and 2.x possible (fabpot)
This PR was merged into the 1.x branch.

Discussion
----------

added a base node visitor to make compat between 1.x and 2.x possible

As suggested in #1644, that allows better compat between 1.x and 2.x

Commits
-------

881fb63 added a base node visitor to make compat between 1.x and 2.x possible
3f521d4 bumped to 1.20
2015-08-11 15:57:52 +02:00
Fabien Potencier 881fb63bf7 added a base node visitor to make compat between 1.x and 2.x possible 2015-08-11 15:38:01 +02:00
Fabien Potencier 492c504dde bug #1752 re-added Twig_Simple* classes to provide more compat between 1.x and 2.x (fabpot)
This PR was merged into the 2.0-dev branch.

Discussion
----------

re-added Twig_Simple* classes to provide more compat between 1.x and 2.x

see #1644

Commits
-------

f4126f0 re-added Twig_Simple* classes to provide more compat between 1.x and 2.x
2015-08-11 15:32:54 +02:00
Fabien Potencier 3f521d483f bumped to 1.20 2015-08-11 15:22:12 +02:00
Fabien Potencier 449578029a fixed obsolete comment 2015-08-11 15:07:59 +02:00
Fabien Potencier f4126f0c71 re-added Twig_Simple* classes to provide more compat between 1.x and 2.x 2015-08-11 15:06:19 +02:00
Fabien Potencier e375c9c562 added a mention of projects using Twig 2015-08-04 16:19:10 +02:00
Fabien Potencier 617eaa0009 bumped version to 1.19.1-DEV 2015-07-31 15:50:08 +02:00
Fabien Potencier edbeaf43b0 prepared the 1.19.0 release v1.19.0 2015-07-31 15:45:26 +02:00
Fabien Potencier b18bcfb390 updated CHANGELOG 2015-07-31 15:35:58 +02:00
Fabien Potencier b1385c056d bug #1746 Fixed error guessing in blocks in a child template (hason)
This PR was merged into the 1.x branch.

Discussion
----------

Fixed error guessing in blocks in a child template

Commits
-------

cfa1404 Fixed error guessing in blocks in a child template
2015-07-31 15:33:46 +02:00
Martin Hasoň cfa14046ab Fixed error guessing in blocks in a child template 2015-07-31 14:43:10 +02:00
Fabien Potencier 4f097f272f updated CHANGELOG 2015-07-28 16:13:53 +02:00
Fabien Potencier b1b4e59f5b fixed CS 2015-07-28 16:12:16 +02:00
Fabien Potencier de864300b0 feature #1708 Bugfix/constructor should not have optional loader (Nikola Svitlica a.k.a. TheCelavi)
This PR was squashed before being merged into the 2.0-dev branch (closes #1708).

Discussion
----------

Bugfix/constructor should not have optional loader

Following #1693 and the fact that "hasLoader" contains semantical error that loader is optional, this PR removes optionality of loader from Environment.

Commits
-------

ac2295c Bugfix/constructor should not have optional loader
2015-07-28 16:11:44 +02:00
Nikola Svitlica a.k.a. TheCelavi ac2295c589 Bugfix/constructor should not have optional loader 2015-07-28 16:11:37 +02:00
Fabien Potencier c53d07a45d minor #1741 Update copyright year (bocharsky-bw)
This PR was merged into the 2.0-dev branch.

Discussion
----------

Update copyright year

Commits
-------

1b6b400 Update copyright year
2015-07-21 00:59:22 +02:00
Bocharsky Victor 1b6b400f4a Update copyright year 2015-07-20 22:22:44 +03:00
Fabien Potencier a3b7fcbfd3 feature #1729 moved protected to private (fabpot)
This PR was merged into the 2.0-dev branch.

Discussion
----------

moved protected to private

Moved some protected properties/methods from protected to private.

I've changed protected properties/methods mostly on internal classes but not where it could potentially break BC too badly with existing code.

Classes where we could change protected to private but where it could be a problem for existing code:

* Twig_ExpressionParser
* Twig_Environment
* Twig_Lexer
* Twig_Node
* Twig_Parser (done in second commit)
* Twig_Template

closes #1645

Commits
-------

56a3791 moved protected to private (more)
dbd0c91 moved protected to private
2015-07-16 01:25:27 +02:00
Fabien Potencier 4e58c4811a added a recipe about rendering a template stored in a string 2015-07-07 09:46:15 +02:00
Fabien Potencier d96a014e68 minor #1730 Remove reference to String loader in docs (simshaun)
This PR was merged into the 2.0-dev branch.

Discussion
----------

Remove reference to `String` loader in docs

Commits
-------

02a7bd6 Remove reference to `String` loader in docs
2015-07-07 09:36:49 +02:00
Shaun 02a7bd6d7e Remove reference to String loader in docs 2015-07-06 15:43:15 -04:00
Fabien Potencier 1ded65daeb fixed CS 2015-07-05 10:50:23 +02:00
Fabien Potencier 0828c0345a tweaked docs 2015-07-05 10:48:49 +02:00
Fabien Potencier e007c178ec feature #1699 Added variadic filters, tests, and functions (hason)
This PR was merged into the 1.x branch.

Discussion
----------

Added variadic filters, tests, and functions

Replaces #1317

```php
$env->addFunction(new Twig_SimpleFunction('foo', function ($a1, array $args = array()) {
}, array('is_variadic' => true));
```
```jinja
{{ foo(1, 2, a="a", b="b") }}
{# foo(1, array(0 => 2, "a" => "a", "b" => "b")); #}
```

Commits
-------

c78656a Added variadic filters, tests, and functions
2015-07-05 10:27:16 +02:00
Fabien Potencier 056bb5dade fixed CS 2015-07-05 10:26:11 +02:00
Fabien Potencier ea2648768e bumped version to 1.19 2015-07-05 10:14:03 +02:00
Fabien Potencier 5020747987 feature #1659 Added support for unconsumed macro arguments (hason)
This PR was merged into the 1.x branch.

Discussion
----------

Added support for unconsumed macro arguments

Fixes #1159 and supplements #1699

Commits
-------

7f00cb9 Added support for unconsumed macro arguments
2015-07-05 10:12:21 +02:00
Fabien Potencier 56a379197d moved protected to private (more) 2015-07-05 08:52:07 +02:00
Fabien Potencier dbd0c9181f moved protected to private 2015-07-05 08:51:42 +02:00
Fabien Potencier 248de72b17 minor #1728 removed some test hacks (fabpot)
This PR was merged into the 2.0-dev branch.

Discussion
----------

removed some test hacks

Commits
-------

ab88c38 removed some test hacks
2015-07-05 08:50:49 +02:00
Fabien Potencier ab88c38a27 removed some test hacks 2015-07-05 08:45:44 +02:00
Fabien Potencier b941b5627a updated phpdoc 2015-07-05 08:04:44 +02:00
Fabien Potencier 43e2bfbd09 minor #1673 Add Twig_ExistsLoaderInterface back for 1.x BC layer #1644 (joelpittet)
This PR was merged into the 2.0-dev branch.

Discussion
----------

Add Twig_ExistsLoaderInterface back for 1.x BC layer #1644

This is the 2.x change for 1.x BC layer of Twig_ExistsLoaderInterface for #1644

Commits
-------

3e546c9 Add Twig_ExistsLoaderInterface back for 1.x BC layer
2015-07-05 08:03:51 +02:00
Fabien Potencier dd2f2129a3 fixed phpdocs 2015-07-04 11:50:19 +02:00
Fabien Potencier 88099932d1 bug #1727 Fix the profiler node visitor signature for Twig 2.0 (stof)
This PR was merged into the 2.0-dev branch.

Discussion
----------

Fix the profiler node visitor signature for Twig 2.0

Commits
-------

e66b07d Fix the profiler node visitor signature for Twig 2.0
2015-07-04 11:48:10 +02:00
Christophe Coevoet e66b07df56 Fix the profiler node visitor signature for Twig 2.0 2015-07-03 14:46:22 +02:00
Fabien Potencier 616c1cceb1 feature #1726 Twig_Template::getContext() removal (fabpot)
This PR was merged into the 2.0-dev branch.

Discussion
----------

Twig_Template::getContext() removal

`Twig_Template::getContext()` is an implementation detail as it is only used on some PHP versions, for some cases. But even with the big warning in the phpdoc, people want to use it, which is a really bad idea. Removing it in 1.x would be kind of a "BC break", so I propose to remove it in 2.0.

Commits
-------

a0261e7 removed code that people want to overide over and over again
2015-07-03 12:15:39 +02:00
Fabien Potencier 336320ee2e removed PHP 5.2 code 2015-07-03 12:15:01 +02:00
Fabien Potencier ff506eb9ab Merge branch '1.x'
* 1.x:
  fixed PHP 5.2 compat
  tweaked previous merge
  add ignore_missing agrument to source function
  updated CHANGELOG
2015-07-03 12:14:51 +02:00
Fabien Potencier 82636dc93d fixed PHP 5.2 compat 2015-07-03 12:11:52 +02:00
Fabien Potencier a0261e7040 removed code that people want to overide over and over again 2015-07-03 12:04:33 +02:00
Fabien Potencier 641090378d tweaked previous merge 2015-07-03 11:46:19 +02:00
Fabien Potencier 35790250b8 bug #1666 add ignore_missing agrument to source function (vetruvet)
This PR was submitted for the master branch but it was merged into the 1.x branch instead (closes #1666).

Discussion
----------

add ignore_missing agrument to source function

This basically works the same way as `ignore_missing` on the `include` function/tag.

Commits
-------

afa9358 add ignore_missing agrument to source function
2015-07-03 11:44:24 +02:00
Valeriy Trubachev afa93586bc add ignore_missing agrument to source function 2015-07-03 11:44:24 +02:00
Fabien Potencier 793ea7e37d updated CHANGELOG 2015-07-03 11:41:40 +02:00
Fabien Potencier bd8a07e89a removed Twig_Environment::clearTemplateCache 2015-07-03 11:33:57 +02:00
Fabien Potencier 4756b19b98 Merge branch '1.x'
* 1.x:
  fixed edge case where tests would fail because of a cache issue
  tweaked docs to avoid using an internal method in an example
  deprecated Twig_Environment::clearTemplateCache()
  fixed sandbox disabling when using the include function
  Example about how to rename several blocks
  fixed docs
  Update batch filter docs with arguments
2015-07-03 11:33:29 +02:00
Fabien Potencier 849adeb85e fixed edge case where tests would fail because of a cache issue 2015-07-03 11:33:17 +02:00
Fabien Potencier d472fcc9bd tweaked docs to avoid using an internal method in an example 2015-07-03 11:30:18 +02:00