Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2922)

Unified Diff: base/allocator/generic_allocators.cc

Issue 419323002: clang/win: Fix a few warnings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: base/allocator/generic_allocators.cc
diff --git a/base/allocator/generic_allocators.cc b/base/allocator/generic_allocators.cc
index d4cf19e952ef23ae944c2b81248ea59a0851c221..5b5f379148c99ec16595ef6d410c60bd5a1ae24c 100644
--- a/base/allocator/generic_allocators.cc
+++ b/base/allocator/generic_allocators.cc
@@ -28,7 +28,7 @@ void* __cdecl operator new(size_t size) {
return generic_cpp_alloc(size, false);
}
-void operator delete(void* p) __THROW {
+void operator delete(void* p) throw() {
free(p);
}
@@ -36,15 +36,15 @@ void* operator new[](size_t size) {
return generic_cpp_alloc(size, false);
}
-void operator delete[](void* p) __THROW {
+void operator delete[](void* p) throw() {
free(p);
}
-void* operator new(size_t size, const std::nothrow_t& nt) __THROW {
+void* operator new(size_t size, const std::nothrow_t& nt) throw() {
return generic_cpp_alloc(size, true);
}
-void* operator new[](size_t size, const std::nothrow_t& nt) __THROW {
+void* operator new[](size_t size, const std::nothrow_t& nt) throw() {
return generic_cpp_alloc(size, true);
}
@@ -53,7 +53,7 @@ void* operator new[](size_t size, const std::nothrow_t& nt) __THROW {
// If flag is 1, calls to malloc will behave like calls to new,
// and the std_new_handler will be invoked on failure.
// Returns the previous mode.
-int _set_new_mode(int flag) __THROW {
+int _set_new_mode(int flag) throw() {
int old_mode = new_mode;
new_mode = flag;
return old_mode;
@@ -63,7 +63,7 @@ int _set_new_mode(int flag) __THROW {
extern "C" {
-void* calloc(size_t n, size_t elem_size) __THROW {
+void* calloc(size_t n, size_t elem_size) {
// Overflow check
const size_t size = n * elem_size;
if (elem_size != 0 && size / elem_size != n) return NULL;

Powered by Google App Engine
This is Rietveld 408576698