wsalloc function

LPWSTR wsalloc(
  1. int wChars

Allocates memory for a Unicode string and returns a pointer.

The parameter indicates how many characters should be allocated. The receiver is responsible for disposing the memory allocated, typically by calling free when it is no longer required.


LPWSTR wsalloc(int wChars) => calloc<WCHAR>(wChars).cast();