Commit migrated from https://github.com/dotnet/corefx/commit/2827f05456d52e4509bb72bf58f20b0c9e5642f2