Theano/Theano — pull request #377 by delallea (2012-01-24 19:05:48+00:00)
Title: Improved scan error message

Two improvements:
- An explicit error is raised if the lambda expression used in scan
returns something that is not made of Theano variables (which may
happen for instance when someone returns a constant value).
- An error is always raised when failing to parse the return value of
the lambda expression

I verified that all scan tests still pass.

@pascanur: Note that the sandbox scan may need a similar improvement (I noticed it is using a similar function). But being in the sandbox I wasn't sure I should bother updating it.