Update Function.toString() tests.
Allow Function.toString() mismatch, but leave it as a TODO with test coverage.
Make sure leaveFunc() gets called on every possibility through which a function can be left, including exceptions.