Bringing this PR up to date with master.