diff --git a/support/tools/TableGen/Record.cpp b/support/tools/TableGen/Record.cpp index d48d987a85a..b33e5e774b7 100644 --- a/support/tools/TableGen/Record.cpp +++ b/support/tools/TableGen/Record.cpp @@ -19,7 +19,6 @@ Init *BitRecTy::convertValue(BitsInit *BI) { Init *BitRecTy::convertValue(IntInit *II) { int Val = II->getValue(); if (Val != 0 && Val != 1) return 0; // Only accept 0 or 1 for a bit! - delete II; return new BitInit(Val != 0); } @@ -50,7 +49,6 @@ Init *BitsRecTy::convertValue(BitInit *UI) { // Init *BitsRecTy::convertValue(IntInit *II) { int Value = II->getValue(); - delete II; BitsInit *Ret = new BitsInit(Size); for (unsigned i = 0; i != Size; ++i) diff --git a/utils/TableGen/Record.cpp b/utils/TableGen/Record.cpp index d48d987a85a..b33e5e774b7 100644 --- a/utils/TableGen/Record.cpp +++ b/utils/TableGen/Record.cpp @@ -19,7 +19,6 @@ Init *BitRecTy::convertValue(BitsInit *BI) { Init *BitRecTy::convertValue(IntInit *II) { int Val = II->getValue(); if (Val != 0 && Val != 1) return 0; // Only accept 0 or 1 for a bit! - delete II; return new BitInit(Val != 0); } @@ -50,7 +49,6 @@ Init *BitsRecTy::convertValue(BitInit *UI) { // Init *BitsRecTy::convertValue(IntInit *II) { int Value = II->getValue(); - delete II; BitsInit *Ret = new BitsInit(Size); for (unsigned i = 0; i != Size; ++i)