Changeset 39088 in vbox for trunk/src/VBox/Runtime/r3
- Timestamp:
- Oct 24, 2011 10:12:20 AM (13 years ago)
- svn:sync-xref-src-repo-rev:
- 74520
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/r3/alloc-ef-cpp.cpp
r39087 r39088 39 39 /** @todo test this on MSC */ 40 40 41 /* MSC declares the operators as cdecl it seems. */41 /** MSC declares the operators as cdecl it seems. */ 42 42 #ifdef _MSC_VER 43 43 # define RT_EF_CDECL __cdecl … … 46 46 #endif 47 47 48 /* MSC doesn't use the standard namespace. */48 /** MSC doesn't use the standard namespace. */ 49 49 #ifdef _MSC_VER 50 50 # define RT_EF_SIZE_T size_t … … 53 53 #endif 54 54 55 /** The hint that we're throwing std::bad_alloc is not apprecitated by MSC. */ 56 #ifdef _MSC_VER 57 # if _MSC_VER >= 1400 58 # define RT_EF_THROWS_BAD_ALLOC 59 # else 60 # define RT_EF_THROWS_BAD_ALLOC throw(std::bad_alloc) 61 # endif 62 #else 63 # define RT_EF_THROWS_BAD_ALLOC throw(std::bad_alloc) 64 #endif 55 65 56 void *RT_EF_CDECL operator new(RT_EF_SIZE_T cb) throw(std::bad_alloc) 66 67 void *RT_EF_CDECL operator new(RT_EF_SIZE_T cb) RT_EF_THROWS_BAD_ALLOC 57 68 { 58 69 void *pv = rtR3MemAlloc("new", RTMEMTYPE_NEW, cb, cb, NULL, ASMReturnAddress(), NULL, 0, NULL); … … 90 101 */ 91 102 92 void *RT_EF_CDECL operator new[](RT_EF_SIZE_T cb) throw(std::bad_alloc)103 void *RT_EF_CDECL operator new[](RT_EF_SIZE_T cb) RT_EF_THROWS_BAD_ALLOC 93 104 { 94 105 void *pv = rtR3MemAlloc("new[]", RTMEMTYPE_NEW_ARRAY, cb, cb, NULL, ASMReturnAddress(), NULL, 0, NULL);
Note:
See TracChangeset
for help on using the changeset viewer.