Microsoft KB Archive/99871

= NEW.H Does Not Contain new that Takes a void* =

Article ID: 99871

Article Last Modified on 7/5/2005

-

APPLIES TO


 * Microsoft C/C++ Professional Development System 7.0
 * Microsoft Visual C++ 1.0 Professional Edition
 * Microsoft Visual C++ 1.51
 * Microsoft Visual C++ 2.0 Professional Edition
 * Microsoft Visual C++ 2.1

-



This article was previously published under Q99871



SUMMARY
The form of operator new that takes a parameter of type &quot;void *&quot; was added in the March '93 ANSI C++ draft document, as Section 17.1.1.3. As such, it is not supported by the Win32 Software Development Kit (SDK) compiler.

This feature may be added to a future Microsoft C/C++ compiler; however, there are certain considerations. If this addition is made to NEW.H, then every C++ program that includes NEW.H in more than one module will receive multiple definition errors. Either the definition must be declared in the CRT or declared INLINE. Furthermore, because the user should be able to replace the definition of &quot;operator new&quot;, the definition must be replaced in the C Run-Time library (CRT) to ensure that it is not inlined into some modules, which would prevent it from being user-replaced.

NOTE: This change was made Visual C++, 32-bit Edition, version 4.0.

Additional query words: kbinf 1.00 1.50 2.00 2.10 2.50 7.00 8.00 8.00c 9.00 9.10 MFC Foundation Classes

Keywords: kblangcpp KB99871

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.