Use string.Create in ConvertFromUtf32 (dotnet/coreclr#21409)
authorStephen Toub <stoub@microsoft.com>
Sat, 8 Dec 2018 04:49:29 +0000 (23:49 -0500)
committerJan Kotas <jkotas@microsoft.com>
Sat, 8 Dec 2018 04:49:29 +0000 (20:49 -0800)
commitf71b0a9d464094eecba3b6fa72d252ec6343125e
treef4d11f8ece0a393ee7da707a8e10bb8965e94ca5
parenta87ac12a0c604e56a93928b94a922d701561a319
Use string.Create in ConvertFromUtf32 (dotnet/coreclr#21409)

* Use string.Create in ConvertFromUtf32

Removes the unsafe code from the method.  Also happens to make it a bit faster.

* Improve Rune.ToString performance

Commit migrated from https://github.com/dotnet/coreclr/commit/ca60cf7c507e73f3bb28de0f7781b201a66cf8d2
src/libraries/System.Private.CoreLib/src/System/Char.cs
src/libraries/System.Private.CoreLib/src/System/String.cs
src/libraries/System.Private.CoreLib/src/System/Text/Rune.cs