The wcs*
functions like wcscpy
are part of the C Standard Library. The _wfopen
function and other _w*
functions are extensions, as are the multibyte string functions like _mbscpy
.
For the most part, Visual C++ C Runtime (CRT) functions that have a leading underscore are extensions; functions that do not have a leading underscore are part of the C Standard Library.
There are two main exceptions, where extensions may not have leading underscores:
There are several extension functions, declared with an underscore prefix, that have prefixless aliases for backwards source compatibility. These aliases are deprecated, and if you try to use them you'll get a suppressable deprecation warning (C4996).
There are
_s
-suffixed secure alternative functions to some C Standard Library functions, e.g.scanf_s
. These are declared by default, but their declarations may be suppressed by defining the macro__STDC_WANT_SECURE_LIB__
to have the value 0.(These functions were actually added to C11 in the optional Annex K, but note that there are a few differences between what is specified in the C Standard and what is implemented by Visual C++. The differences are due to a historical accident.)