Updated to bring in-line with recent changes to the core library.