Nóta
Teastaíonn údarú chun rochtain a fháil ar an leathanach seo. Is féidir leat triail a bhaint as shíniú isteach nó eolairí a athrú.
Teastaíonn údarú chun rochtain a fháil ar an leathanach seo. Is féidir leat triail a bhaint as eolairí a athrú.
'identifier' : must be a function of type 'type'
Remarks
Your code declares a version of the atexit function that does not match the version declared internally by the compiler. Declare atexit as follows:
int __cdecl atexit(void (__cdecl *)());
For more information, see init_seg.
Example
The following example generates C2357:
// C2357.cpp
// compile with: /c
// C2357 expected
#pragma warning(disable : 4075)
// Uncomment the following line to resolve.
// int __cdecl myexit(void (__cdecl *)());
#pragma init_seg(".mine$m",myexit)