Merge call branch from Elliot Fairweather with cleanups from Xavier Claessens.