updated demo code to use the non-deprecated features of Twig
merged branch fabpot/twig-deprecated-features (PR #580)

This PR was merged into the 2.2 branch.

Discussion
----------

Twig deprecated features

see symfony/symfony#8675

Commits
-------

35a5826 updated demo code to use the non-deprecated features of Twig