Make the Twig extension class Symfony-ified

Signed-off-by: Gawain Lynch <gawain.lynch@gmail.com>