More intelligently find locals when assigning, looping, excepting.

Just on principle, would make me happier if you put newlines at the ends of these assertion strings:  `'\n_v = bar\n'`