klen/python-mode — pull request #500 by wilywampa (2014-11-17 21:14:29+00:00)
Title: Handle folding of nested defs correctly

With the current folding algorithm, a function definition nested at the top of another function causes the whole outer function to be folded in with the nested function. See https://github.com/klen/python-mode/issues/489 for an example. This changeset solves that problem.