The information in this article applies to:
SYMPTOMSThe notation for an explicit call of a destructor may be used for any simple type name. Using the notation for a type that does not have a destructor has no effect. However, for the products mentioned previously, the use of a simple type name causes the following compiler errors:
RESOLUTIONThe Annotated C++ Reference Manual (Jan '94), section 12.4 contains the following example:
However, the current language grammar restricts the use of the ->~ and :: syntax to class names. Because at the current time simple types are not
considered class names, the above syntax is not implemented by the
compiler.
Until this language feature is implemented, removing the code is the only resolution. STATUSMicrosoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. MORE INFORMATIONUsing an explicit call of a destructor for a simple type would have no effect, so removing it will not affect the compiled code. However, this may not be easy to do when this code is part of a macro expansion or templated class that should be able to accept both built-in and user-defined types. REFERENCESFor more information, see The Annotated C++ Reference Manual (Jan '94), section 12.4. Sample Code
Additional query words: kbVC400bug 8.00 8.00c 9.00 9.10 template 10.00 10.10 10.20
Keywords : kbCompiler kbCPPonly kbVC kbVC100bug kbVC150bug kbVC151bug kbVC152bug kbVC200bug kbVC210bug kbVC220bug kbVC400bug kbVC410 kbVC420bug kbVC500bug kbVC600bug |
Last Reviewed: May 27, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |