Skip to content

Commit 57ebe4b

Browse files
authored
Update Marshal.PtrToStringAnsi - UTF-8 on Unix (#4238)
* Update Marshal.PtrToStringAnsi - UTF-8 on Unix * Change mentions of Unicode to UTF-16
1 parent 12efe13 commit 57ebe4b

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

xml/System.Runtime.InteropServices/Marshal.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6168,7 +6168,7 @@ There is a difference in the behavior of the `GetLastWin32Error` method on .NET
61686168
<AssemblyVersion>4.2.0.0</AssemblyVersion>
61696169
</AssemblyInfo>
61706170
<Docs>
6171-
<summary>Allocates a managed <see cref="T:System.String" /> and copies all or part of an unmanaged ANSI string into it.</summary>
6171+
<summary>Allocates a managed <see cref="T:System.String" /> and copies all or part of an unmanaged ANSI (on Windows) or UTF-8 (on Unix) string into it.</summary>
61726172
</Docs>
61736173
</MemberGroup>
61746174
<Member MemberName="PtrToStringAnsi">
@@ -6216,8 +6216,8 @@ There is a difference in the behavior of the `GetLastWin32Error` method on .NET
62166216
</Parameters>
62176217
<Docs>
62186218
<param name="ptr">The address of the first character of the unmanaged string.</param>
6219-
<summary>Copies all characters up to the first null character from an unmanaged ANSI string to a managed <see cref="T:System.String" />, and widens each ANSI character to Unicode.</summary>
6220-
<returns>A managed string that holds a copy of the unmanaged ANSI string. If <paramref name="ptr" /> is <see langword="null" />, the method returns a null string.</returns>
6219+
<summary>Copies all characters up to the first null character from an unmanaged ANSI or UTF-8 string to a managed <see cref="T:System.String" />, and widens each character to UTF-16.</summary>
6220+
<returns>A managed string that holds a copy of the unmanaged string. If <paramref name="ptr" /> is <see langword="null" />, the method returns a null string.</returns>
62216221
<remarks>
62226222
<format type="text/markdown"><![CDATA[
62236223

@@ -6284,8 +6284,8 @@ There is a difference in the behavior of the `GetLastWin32Error` method on .NET
62846284
<Docs>
62856285
<param name="ptr">The address of the first character of the unmanaged string.</param>
62866286
<param name="len">The byte count of the input string to copy.</param>
6287-
<summary>Allocates a managed <see cref="T:System.String" />, copies a specified number of characters from an unmanaged ANSI string into it, and widens each ANSI character to Unicode.</summary>
6288-
<returns>A managed string that holds a copy of the native ANSI string if the value of the <paramref name="ptr" /> parameter is not <see langword="null" />; otherwise, this method returns <see langword="null" />.</returns>
6287+
<summary>Allocates a managed <see cref="T:System.String" />, copies a specified number of characters from an unmanaged ANSI or UTF-8 string into it, and widens each character to UTF-16.</summary>
6288+
<returns>A managed string that holds a copy of the native string if the value of the <paramref name="ptr" /> parameter is not <see langword="null" />; otherwise, this method returns <see langword="null" />.</returns>
62896289
<remarks>
62906290
<format type="text/markdown"><![CDATA[
62916291

0 commit comments

Comments
 (0)