sinatra/sinatra — pull request #531 by blambeau (2012-06-14 08:06:55+00:00)
Title: Better integration with Tilt

This pull request towards the following features (see #529 for original motivation):

* ability to render a template from a path, as Tilt already allows, with the cache automatically enabled
* ability to render a template without knowing the corresponding engine a priori. A logical consequence of the first point.

The first commit replaces `compile_template` by a new greedy algorithm called `tilt_template`. The latter recursively discovers the parameters needed by Tilt::Template.new, from a bunch of different possible signatures, including those that don't a priori know the engine.

The stuff is fully backward compatible and passes all the tests. I still need to implement the new features above on this basis.