mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0022815: Missing delete operator for placement new
This commit is contained in:
@@ -7,11 +7,6 @@
|
||||
#include <LDOM_BasicAttribute.hxx>
|
||||
#include <LDOM_MemManager.hxx>
|
||||
|
||||
#ifdef WNT
|
||||
// Disable the warning: "operator new unmatched by delete"
|
||||
#pragma warning (disable:4291)
|
||||
#endif
|
||||
|
||||
//=======================================================================
|
||||
//function : LDOM_BasicAttribute
|
||||
//purpose :
|
||||
|
@@ -15,20 +15,12 @@ class LDOM_Element;
|
||||
class LDOM_Attr;
|
||||
class LDOM_Node;
|
||||
|
||||
#ifdef WNT
|
||||
// Disable the warning: "operator new unmatched by delete"
|
||||
#pragma warning (push)
|
||||
#pragma warning (disable:4291)
|
||||
#endif
|
||||
|
||||
// Class LDOM_BasicAttribute
|
||||
//
|
||||
|
||||
class LDOM_BasicAttribute : public LDOM_BasicNode
|
||||
{
|
||||
public:
|
||||
void * operator new (size_t, void * anAddress) { return anAddress; }
|
||||
|
||||
// ---------- PUBLIC METHODS ----------
|
||||
|
||||
LDOM_BasicAttribute () : LDOM_BasicNode (LDOM_Node::UNKNOWN) {}
|
||||
@@ -72,8 +64,4 @@ class LDOM_BasicAttribute : public LDOM_BasicNode
|
||||
LDOMBasicString myValue;
|
||||
};
|
||||
|
||||
#ifdef WNT
|
||||
#pragma warning (pop)
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@@ -9,11 +9,6 @@
|
||||
#include <LDOM_BasicText.hxx>
|
||||
#include <LDOM_MemManager.hxx>
|
||||
|
||||
#ifdef WNT
|
||||
// Disable the warning: "operator new unmatched by delete"
|
||||
#pragma warning (disable:4291)
|
||||
#endif
|
||||
|
||||
//=======================================================================
|
||||
//function : Create
|
||||
//purpose : construction in the Document's data pool
|
||||
|
@@ -17,19 +17,12 @@ class LDOM_NodeList;
|
||||
class LDOM_Element;
|
||||
class LDOM_BasicAttribute;
|
||||
|
||||
#ifdef WNT
|
||||
// Disable the warning: "operator new unmatched by delete"
|
||||
#pragma warning (push)
|
||||
#pragma warning (disable:4291)
|
||||
#endif
|
||||
|
||||
// Class LDOM_BasicElement
|
||||
//
|
||||
|
||||
class LDOM_BasicElement : public LDOM_BasicNode
|
||||
{
|
||||
public:
|
||||
void * operator new (size_t, void * anAddress) { return anAddress; }
|
||||
|
||||
// ---------- PUBLIC METHODS ----------
|
||||
|
||||
@@ -128,8 +121,4 @@ class LDOM_BasicElement : public LDOM_BasicNode
|
||||
LDOM_BasicNode * myFirstChild;
|
||||
};
|
||||
|
||||
#ifdef WNT
|
||||
#pragma warning (pop)
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@@ -18,6 +18,9 @@ class LDOMParser;
|
||||
|
||||
class LDOM_BasicNode
|
||||
{
|
||||
public:
|
||||
DEFINE_STANDARD_ALLOC
|
||||
|
||||
public:
|
||||
|
||||
Standard_Boolean isNull () const {return myNodeType ==LDOM_Node::UNKNOWN;}
|
||||
|
@@ -8,11 +8,6 @@
|
||||
#include <LDOM_BasicText.hxx>
|
||||
#include <LDOM_MemManager.hxx>
|
||||
|
||||
#ifdef WNT
|
||||
// Disable the warning: "operator new unmatched by delete"
|
||||
#pragma warning (disable:4291)
|
||||
#endif
|
||||
|
||||
//=======================================================================
|
||||
//function : LDOM_BasicText()
|
||||
//purpose : Constructor
|
||||
|
@@ -15,19 +15,12 @@ class LDOM_CharacterData;
|
||||
class LDOMParser;
|
||||
class LDOM_BasicElement;
|
||||
|
||||
#ifdef WNT
|
||||
// Disable the warning: "operator new unmatched by delete"
|
||||
#pragma warning (push)
|
||||
#pragma warning (disable:4291)
|
||||
#endif
|
||||
|
||||
// Class LDOM_BasicText
|
||||
//
|
||||
|
||||
class LDOM_BasicText : public LDOM_BasicNode
|
||||
{
|
||||
public:
|
||||
void * operator new (size_t, void * anAddress) { return anAddress; }
|
||||
|
||||
// ---------- PUBLIC METHODS ----------
|
||||
|
||||
@@ -69,8 +62,4 @@ class LDOM_BasicText : public LDOM_BasicNode
|
||||
LDOMBasicString myValue;
|
||||
};
|
||||
|
||||
#ifdef WNT
|
||||
#pragma warning (pop)
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user