]> granicus.if.org Git - clang/commitdiff
Remove throw() from Stmt::operator new so the compiler will omit the null check on...
authorCraig Topper <craig.topper@gmail.com>
Sun, 18 Aug 2013 17:45:38 +0000 (17:45 +0000)
committerCraig Topper <craig.topper@gmail.com>
Sun, 18 Aug 2013 17:45:38 +0000 (17:45 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@188641 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/AST/Stmt.h
lib/AST/Stmt.cpp

index 834a3dc1c0f527227a47d0c440feb7d1c3cda973..bc5dabb5ac90774f359486aa0710130febde0fdc 100644 (file)
@@ -313,10 +313,10 @@ public:
   // Only allow allocation of Stmts using the allocator in ASTContext
   // or by doing a placement new.
   void* operator new(size_t bytes, const ASTContext& C,
-                     unsigned alignment = 8) throw();
+                     unsigned alignment = 8);
 
   void* operator new(size_t bytes, const ASTContext* C,
-                     unsigned alignment = 8) throw();
+                     unsigned alignment = 8);
 
   void* operator new(size_t bytes, void* mem) throw() {
     return mem;
index 87e55a2fb9d99e1673ffdbdf85cefaefc4f89def..a80bd87d216b4aff52bd16cc9c39780b445ac889 100644 (file)
@@ -50,12 +50,12 @@ static StmtClassNameTable &getStmtInfoTableEntry(Stmt::StmtClass E) {
 }
 
 void *Stmt::operator new(size_t bytes, const ASTContext& C,
-                         unsigned alignment) throw() {
+                         unsigned alignment) {
   return ::operator new(bytes, C, alignment);
 }
 
 void *Stmt::operator new(size_t bytes, const ASTContext* C,
-                         unsigned alignment) throw() {
+                         unsigned alignment) {
   return ::operator new(bytes, *C, alignment);
 }