kernel/eka/compsupp/symcpp/symcpp.h
changeset 9 96e5fb8b040d
child 10 36bfc973b146
equal deleted inserted replaced
-1:000000000000 9:96e5fb8b040d
       
     1 /*
       
     2 * Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description: 
       
    15 * This is a preinclude file for the Symbian C++ specific defintions for RVCT.
       
    16 *
       
    17 */
       
    18 
       
    19 #ifdef __cplusplus
       
    20 namespace std {
       
    21 	struct nothrow_t { };
       
    22 	extern const nothrow_t nothrow;
       
    23 }
       
    24 
       
    25 #ifndef __OPERATOR_NEW_DECLARED__
       
    26 #define __OPERATOR_NEW_DECLARED__
       
    27 
       
    28 /* e32cmn.h also declares these five overloads, but slightly differently, so use
       
    29  * __OPERATOR_NEW_DECLARED__ to avoid the declarations here (included by compiler-specific
       
    30  * pre-include files) from conflicting.
       
    31  */
       
    32 
       
    33 IMPORT_C void* operator new(unsigned int aSize) __NO_THROW;
       
    34 
       
    35 IMPORT_C void* operator new(unsigned int aSize,unsigned int aSize1) __NO_THROW;
       
    36 
       
    37 IMPORT_C void* operator new[](unsigned int aSize) __NO_THROW;
       
    38 
       
    39 IMPORT_C void operator delete(void* aPtr) __NO_THROW;
       
    40 
       
    41 IMPORT_C void operator delete[](void* aPtr) __NO_THROW;
       
    42 
       
    43 #endif // !__OPERATOR_NEW_DECLARED__
       
    44 
       
    45 
       
    46 /* The following four overloads are not declared by the generic Symbian headers, so
       
    47  * do not need to be protected by __OPERATOR_NEW_DECLARED__.
       
    48  */
       
    49 
       
    50 IMPORT_C void* operator new(unsigned int aSize, const std::nothrow_t& aNoThrow) __NO_THROW;
       
    51 
       
    52 IMPORT_C void* operator new[](unsigned int aSize, const std::nothrow_t& aNoThrow) __NO_THROW;
       
    53 
       
    54 IMPORT_C void operator delete(void* aPtr, const std::nothrow_t& aNoThrow) __NO_THROW;
       
    55 
       
    56 IMPORT_C void operator delete[](void* aPtr, const std::nothrow_t& aNoThrow) __NO_THROW;
       
    57 
       
    58 #endif