equal
deleted
inserted
replaced
|
1 // Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of the License "ARM EABI LICENCE.txt" |
|
5 // which accompanies this distribution, and is available |
|
6 // in kernel/eka/compsupp. |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // |
|
15 |
|
16 //#include <stddef.h> |
|
17 #include <e32std.h> |
|
18 #include <e32std_private.h> |
|
19 //#include <e32math.h> |
|
20 //#include "uc_std.h" |
|
21 |
|
22 EXPORT_C TAny* operator new(TUint aSize) __NO_THROW |
|
23 // |
|
24 // The global new operator. |
|
25 // |
|
26 { |
|
27 |
|
28 return(User::Alloc(aSize)); |
|
29 } |
|
30 |
|
31 EXPORT_C TAny* operator new[](TUint aSize) __NO_THROW |
|
32 { |
|
33 |
|
34 return(User::Alloc(aSize)); |
|
35 } |
|
36 |
|
37 EXPORT_C TAny* operator new(TUint aSize, const std::nothrow_t& aNoThrow) __NO_THROW |
|
38 // |
|
39 // The global new operator. |
|
40 // |
|
41 { |
|
42 (void) aNoThrow; |
|
43 return(User::Alloc(aSize)); |
|
44 } |
|
45 |
|
46 EXPORT_C TAny* operator new[](TUint aSize, const std::nothrow_t& aNoThrow) __NO_THROW |
|
47 { |
|
48 (void) aNoThrow; |
|
49 return(User::Alloc(aSize)); |
|
50 } |
|
51 |
|
52 EXPORT_C TAny* operator new(TUint aSize,TUint anExtraSize) __NO_THROW |
|
53 // |
|
54 // Allocate the requested size plus the extra. |
|
55 // |
|
56 { |
|
57 |
|
58 return(User::Alloc(aSize+anExtraSize)); |
|
59 } |