From 8efb7ee366250ccc993788aa237b7df53152c58f Mon Sep 17 00:00:00 2001 From: Armin Ronacher Date: Tue, 6 Nov 2007 19:01:09 +0100 Subject: [PATCH] fix #284 --HG-- branch : trunk --- jinja/_speedups.c | 2 +- jinja/parser.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/jinja/_speedups.c b/jinja/_speedups.c index 70f0bf1..dfabf1d 100644 --- a/jinja/_speedups.c +++ b/jinja/_speedups.c @@ -440,7 +440,7 @@ static PyTypeObject BaseContextType = { 0, /* tp_as_buffer */ Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /*tp_flags*/ "", /* tp_doc */ - (traverseproc)BaseContext_traverse, /* tp_traverse */ + (traverseproc)BaseContext_traverse, /* tp_traverse */ 0, /* tp_clear */ 0, /* tp_richcompare */ 0, /* tp_weaklistoffset */ diff --git a/jinja/parser.py b/jinja/parser.py index a3a8347..44ea954 100644 --- a/jinja/parser.py +++ b/jinja/parser.py @@ -1096,9 +1096,9 @@ class Parser(object): self.stream.current.type, lineno, self.filename) else: + name = self.stream.current.value raise TemplateSyntaxError('unknown directive %r.' % - self.stream.current.type, - lineno, self.filename) + name, lineno, self.filename) else: node = handler() if node is not None: -- 2.26.2