]> git.ipfire.org Git - thirdparty/tornado.git/commit
Fix template errors with empty blocks.
authorBen Darnell <ben@bendarnell.com>
Mon, 27 Aug 2012 01:03:12 +0000 (18:03 -0700)
committerBen Darnell <ben@bendarnell.com>
Mon, 27 Aug 2012 01:03:12 +0000 (18:03 -0700)
commit54d91d5e1312eb2e3d0c9ae0b7f5c8333a4ac50e
treea4baebd360662d1a697d6e8757e4dc8fdf8601d8
parent58671703d35937d98898ff76571513b6c9678451
Fix template errors with empty blocks.

Emits a "pass" statement in every generated block whether it's empty or not;
I verified with the disassembler that the unnecessary pass statements
don't generate extra bytecodes.

Closes #546.
tornado/template.py
tornado/test/template_test.py