Permalink
Switch branches/tags
Commits on Sep 10, 2011
  1. prepared 1.2.0-RC1 release

    fabpot committed Sep 10, 2011
Commits on Sep 6, 2011
  1. updated CHANGELOG

    fabpot committed Sep 6, 2011
  2. merged branch maxromanovsky/master (PR #431)

    fabpot committed Sep 6, 2011
    Commits
    -------
    
    4b95621 Added: Countable interface support for empty test
    
    Discussion
    ----------
    
    Countable interface support for empty test
    
    See [issue](https://github.com/fabpot/Twig/issues/430)
Commits on Sep 4, 2011
Commits on Sep 1, 2011
  1. added more unit tests

    fabpot committed Sep 1, 2011
  2. made a markup refactoring

    fabpot committed Sep 1, 2011
  3. fixed algorithm that determines if a template using inheritance is va…

    fabpot committed Sep 1, 2011
    …lid (no output between block definitions)
  4. tweaked an error message

    fabpot committed Sep 1, 2011
Commits on Aug 31, 2011
Commits on Aug 30, 2011
  1. added better support for encoding problems when escaping a string (av…

    fabpot committed Aug 30, 2011
    …ailable as of PHP 5.4)
    
    From the PHP CHANGELOG:
    
    The flag ENT_SUBSTITUTE makes invalid multibyte sequences be replaced by
    U+FFFD (UTF-8) or &#FFFD; by htmlspecialchars and htmlentities. It is an
    alternative to the default behavior, which just returns an empty string and to
    ENT_IGNORE, which is a security risk. The behavior follows the recommendations
    of Unicode Technical Report #36.
  2. Removing array_shift for optimisation.

    joelwurtz committed Aug 30, 2011
    For example we check if a template and use exception to redirect to a default template
    
    Before : We checked ~1000 times => 100sec due to array_shift
    After  : ~1sec
Commits on Aug 29, 2011
  1. simplified previous merge

    fabpot committed Aug 29, 2011
  2. fixed CS

    fabpot committed Aug 29, 2011
  3. merged branch Brouznouf/patch-1 (PR #425)

    fabpot committed Aug 29, 2011
    Commits
    -------
    
    4dc490f Removing array_shift for optimisation.
    
    Discussion
    ----------
    
    Removing array_shift for optimisation.
    
    For example we check if a template and use exception to redirect to a default template
    
    Before : We checked ~1000 times => 100sec due to array_shift
    After  : ~1sec
Commits on Aug 28, 2011
  1. fixed markup in the doc

    fabpot committed Aug 28, 2011
Commits on Aug 27, 2011
  1. updated CHANGELOG

    fabpot committed Aug 27, 2011
  2. merged branch jturmel/master (PR #403)

    fabpot committed Aug 27, 2011
    Commits
    -------
    
    c2c01de Add bitwise operators to core
    
    Discussion
    ----------
    
    Added bitwise operators (and, xor, or) to core
    
    * Added bitwise operators (and, xor, or) to core
    
    ---------------------------------------------------------------------------
    
    by nikic at 2011/08/02 21:02:14 -0700
    
    I'm not sure bitwise ops really belong into a templateing language...
    
    ---------------------------------------------------------------------------
    
    by jturmel at 2011/08/02 21:06:02 -0700
    
    That's a general statement to make without knowing why it was implemented at all... no one is forced to use them, however when you do need them, them not being available makes you have relegate something that should be in the view in the particular case I needed them, to be done in a controller instead, which would be quite a bit nastier in my case.
    
    ---------------------------------------------------------------------------
    
    by nikic at 2011/08/02 23:23:30 -0700
    
    @jturmel: I do not doubt that there are some cases where bitwise operations are useful. I can't think of one of the top of my head, though I imagine that it could be useful when using bitwise right management or something like that. What I was trying to say is, that I don't really believe that there are enough significant use cases for bitwise ops to justify adding them to the core (I know, "You Don't Have To Use It!", but it isn't good to clutter the core with features nearly no one uses). Maybe you could give an example of what you needed them for?
    
    ---------------------------------------------------------------------------
    
    by jturmel at 2011/08/02 23:41:36 -0700
    
    It would be one thing if I was implementing some operator that didn't normally exist in PHP itself, but it seems a bit odd to even say that it's cluttering it up, it's 3 lines of code that add 3 missing standard operators from PHP.
    
    Simply put, I have an object that gets passed to the template that has many properties, these properties are bit values, I need to do checks on them to select/deselect various checkboxes in a grid... this is the cleanest way to do it without mudding up controller code with view logic.
    
    ---------------------------------------------------------------------------
    
    by jalliot at 2011/08/03 01:42:56 -0700
    
    Why not adding ``<<`` and ``>>`` then @jturmel?
    I don't have a particular use case but I think that if Twig includes those 3 operators, it should also support these 2 to be "complete". What do you think?
    
    ---------------------------------------------------------------------------
    
    by jturmel at 2011/08/03 06:07:46 -0700
    
    Of course, if you guys think we need the shifting operators as well, we can... but modifying data in the view seems much less practical than the one's I added, although I did miss NOT.
    
    ---------------------------------------------------------------------------
    
    by jalliot at 2011/08/03 06:16:38 -0700
    
    I forgot about ``~`` but sure it should be included as well.
    As for ``<<`` and ``>>``, they could also be used for verifying grant access for example in some implementations.
    ``{% if some_var << some_other_var & 1 %}``
  3. replace file_exists() by is_file() as this is semantically more corre…

    fabpot committed Aug 27, 2011
    …ct (we don't want dirs to match)
Commits on Aug 24, 2011
  1. added Twig_Loader_Chain

    fabpot committed Aug 24, 2011
  2. renamed a test file

    fabpot committed Aug 24, 2011
Commits on Aug 18, 2011
  1. merged branch videlalvaro/patch-1 (PR #419)

    fabpot committed Aug 18, 2011
    Commits
    -------
    
    0ef1cb0 Edited doc/templates.rst via GitHub
    
    Discussion
    ----------
    
    Edited doc/templates.rst via GitHub
    
    I fixed a typo: Variables can by for Variables can be
Commits on Aug 16, 2011
Commits on Aug 8, 2011
Commits on Aug 7, 2011
  1. moved some logic to the constructor (that's allows visitors to have t…

    fabpot committed Aug 7, 2011
    …he real node that will be compiled)