rewrote template parser to do single pass parsing
TODO: handle nested blocks