Move some code around so that it's placed in logical groups.
Improve the heuristic for when to split the line in the presence of a contianer.

This just makes the heuristic fairly straight-forward. If we can fit the
container on the current line, do so. If we can't, and the line already
has items on it, then break the line and try again. Otherwise, just try
our best to fit it on the line, breaking when we need to.
Merge branch 'master' of https://github.com/hhatto/autopep8