newer standards prefer nullptr over NULL - this is most of them but there are others too

This commit is contained in:
DarthArgus
2016-02-15 00:07:31 -06:00
parent 6bb5137dc4
commit 03dc62efba
937 changed files with 14983 additions and 14983 deletions
@@ -22,9 +22,9 @@ using namespace DB;
BindableVarray::BindableVarray() :
m_initialized(false),
m_tdo (NULL),
m_data (NULL),
m_session (NULL)
m_tdo (nullptr),
m_data (nullptr),
m_session (nullptr)
{
}
@@ -52,7 +52,7 @@ bool BindableVarray::create(DB::Session *session, const std::string &name, const
schema.length(),
reinterpret_cast<OraText*>(const_cast<char*>(name.c_str())),
name.length(),
NULL,
nullptr,
0,
OCI_DURATION_SESSION,
OCI_TYPEGET_HEADER,
@@ -64,7 +64,7 @@ bool BindableVarray::create(DB::Session *session, const std::string &name, const
localSession->errhp,
localSession->svchp,
OCI_TYPECODE_VARRAY,
m_tdo, NULL,
m_tdo, nullptr,
OCI_DURATION_DEFAULT,
true,
reinterpret_cast<void**>(&m_data)))))
@@ -86,9 +86,9 @@ void BindableVarray::free()
OCIObjectFree (localSession->envhp,
localSession->errhp, m_data, 0)));
m_initialized = false;
m_tdo=NULL;
m_data=NULL;
m_session=NULL;
m_tdo=nullptr;
m_data=nullptr;
m_session=nullptr;
}
// ----------------------------------------------------------------------
@@ -354,7 +354,7 @@ std::string BindableVarrayNumber::outputValue() const
if (exists)
{
if (*indicator == OCI_IND_NULL)
result += "NULL";
result += "nullptr";
else
{
double value;
@@ -400,7 +400,7 @@ bool BindableVarrayString::push_back(const Unicode::String &value)
bool BindableVarrayString::push_back(const std::string &value)
{
OCIString *buffer = NULL;
OCIString *buffer = nullptr;
OCIInd buffer_indicator (OCI_IND_NOTNULL);
OCISession *localSession = safe_cast<OCISession*>(m_session);
@@ -437,7 +437,7 @@ bool BindableVarrayString::push_back(bool bvalue)
else
value = "N";
OCIString *buffer = NULL;
OCIString *buffer = nullptr;
OCIInd buffer_indicator (OCI_IND_NOTNULL);
OCISession *localSession = safe_cast<OCISession*>(m_session);
@@ -469,7 +469,7 @@ bool BindableVarrayString::push_back(bool IsNULL, const Unicode::String &value)
bool BindableVarrayString::push_back(bool IsNULL, const std::string &value)
{
OCIString *buffer = NULL;
OCIString *buffer = nullptr;
OCIInd buffer_indicator;
if ( IsNULL )
{
@@ -515,7 +515,7 @@ bool BindableVarrayString::push_back(bool IsNULL, bool bvalue)
else
value = "N";
OCIString *buffer = NULL;
OCIString *buffer = nullptr;
OCIInd buffer_indicator;
if ( IsNULL )
{
@@ -568,14 +568,14 @@ std::string BindableVarrayString::outputValue() const
if (exists)
{
if (*indicator == OCI_IND_NULL)
result += "NULL";
result += "nullptr";
else
{
OraText * text = OCIStringPtr(localSession->envhp, *element);
if (text)
result += '"' + std::string(reinterpret_cast<char*>(text)) + '"';
else
result += "NULL";
result += "nullptr";
}
}
else