[4.1] Fixes

I've made a few micro-optimisations again, and made some ocd fixes...

Take a look without the white spaces changes to see what I actually changed: https://github.com/laravel/framework/pull/4220/files?w=1.