This fixes the build issue identified in #5664 at the toolchain level rather than working around it in our own build. The next step in fixing this will be to remove the nightly override in the future when the toolchain becomes stable.