string2wstring

Converts a string to a wstring using a buffer provided by the user. To get the buffer requirements call wstringSize on your source buffer.

@nogc nothrow pure
wchar[]
string2wstring
(
in char[] src
,
wchar* dst
)

Parameters

src char[]

The UTF-8 string to convert.

dst wchar*

The destination buffer for the conversion.

Return Value

Type: wchar[]

The part of the destination buffer used for the conversion as a wchar[]. A terminating zero is appended, so the result.ptr can be passed into Windows APIs.

Meta