From 18dadd526953aa60cb35744f1fb60ad17760bcdc Mon Sep 17 00:00:00 2001 From: Sean McBride Date: Wed, 2 Oct 2019 18:32:12 -0400 Subject: [PATCH] Fixed a bunch of -Wzero-as-null-pointer-constant - most fixed automatically by clang - a few fixed manually by me (especially in macros) --- Common/DataModel/vtkHyperTreeGrid.cxx | 2 +- .../vtkHyperTreeGridNonOrientedCursor.cxx | 2 +- ...HyperTreeGridNonOrientedGeometryCursor.cxx | 2 +- ...vtkHyperTreeGridNonOrientedSuperCursor.cxx | 2 +- ...perTreeGridNonOrientedSuperCursorLight.cxx | 2 +- .../vtkHyperTreeGridOrientedCursor.cxx | 2 +- ...vtkHyperTreeGridOrientedGeometryCursor.cxx | 2 +- Common/DataModel/vtkHyperTreeGridTools.h | 2 +- Common/DataModel/vtkUniformHyperTreeGrid.cxx | 2 +- Filters/Core/vtkExplicitStructuredGridCrop.h | 2 +- ...vtkExplicitStructuredGridSurfaceFilter.cxx | 10 ++++----- .../vtkAdaptiveDataSetSurfaceFilter.cxx | 6 ++--- .../HyperTree/vtkHyperTreeGridAxisClip.cxx | 2 +- Filters/HyperTree/vtkHyperTreeGridAxisCut.cxx | 2 +- .../vtkHyperTreeGridAxisReflection.cxx | 2 +- .../HyperTree/vtkHyperTreeGridCellCenters.cxx | 2 +- Filters/HyperTree/vtkHyperTreeGridContour.cxx | 2 +- .../vtkHyperTreeGridEvaluateCoarse.cxx | 4 ++-- .../HyperTree/vtkHyperTreeGridGeometry.cxx | 6 ++--- .../Modeling/vtkCollisionDetectionFilter.cxx | 2 +- IO/Exodus/vtkExodusIIReader.cxx | 2 +- IO/ParallelExodus/vtkPExodusIIReader.cxx | 22 +++++++++---------- .../Volume/vtkFixedPointVolumeRayCastHelper.h | 2 +- Testing/Core/vtkTestConditionals.txx | 2 +- Utilities/DICOMParser/DICOMParser.cxx | 2 +- 25 files changed, 44 insertions(+), 44 deletions(-) diff --git a/Common/DataModel/vtkHyperTreeGrid.cxx b/Common/DataModel/vtkHyperTreeGrid.cxx index ee4c7f671e..5ece6b79c4 100644 --- a/Common/DataModel/vtkHyperTreeGrid.cxx +++ b/Common/DataModel/vtkHyperTreeGrid.cxx @@ -734,7 +734,7 @@ unsigned int vtkHyperTreeGrid::GetNumberOfLevels() vtkHyperTreeGrid::vtkHyperTreeGridIterator it; this->InitializeTreeIterator(it); vtkHyperTree* tree = nullptr; - while ((tree = it.GetNextTree()) != 0) + while ((tree = it.GetNextTree()) != nullptr) { const vtkIdType nl = tree->GetNumberOfLevels(); if (nl > nLevels) diff --git a/Common/DataModel/vtkHyperTreeGridNonOrientedCursor.cxx b/Common/DataModel/vtkHyperTreeGridNonOrientedCursor.cxx index b94a5c48e7..efacd11cc6 100644 --- a/Common/DataModel/vtkHyperTreeGridNonOrientedCursor.cxx +++ b/Common/DataModel/vtkHyperTreeGridNonOrientedCursor.cxx @@ -29,7 +29,7 @@ vtkHyperTreeGridNonOrientedCursor* vtkHyperTreeGridNonOrientedCursor::Clone() { vtkHyperTreeGridNonOrientedCursor* clone = this->NewInstance(); assert( "post: clone_exists" && - clone != 0 ); + clone != nullptr ); // Copy clone->Grid = this->Grid; clone->Tree = this->Tree; diff --git a/Common/DataModel/vtkHyperTreeGridNonOrientedGeometryCursor.cxx b/Common/DataModel/vtkHyperTreeGridNonOrientedGeometryCursor.cxx index d8c9c376fc..f1a1dbfe1a 100644 --- a/Common/DataModel/vtkHyperTreeGridNonOrientedGeometryCursor.cxx +++ b/Common/DataModel/vtkHyperTreeGridNonOrientedGeometryCursor.cxx @@ -32,7 +32,7 @@ vtkHyperTreeGridNonOrientedGeometryCursor* vtkHyperTreeGridNonOrientedGeometryCu { vtkHyperTreeGridNonOrientedGeometryCursor* clone = this->NewInstance(); assert( "post: clone_exists" && - clone != 0 ); + clone != nullptr ); // Copy clone->Grid = this->Grid; clone->Tree = this->Tree; diff --git a/Common/DataModel/vtkHyperTreeGridNonOrientedSuperCursor.cxx b/Common/DataModel/vtkHyperTreeGridNonOrientedSuperCursor.cxx index 6a51f35f50..37944fd8d8 100644 --- a/Common/DataModel/vtkHyperTreeGridNonOrientedSuperCursor.cxx +++ b/Common/DataModel/vtkHyperTreeGridNonOrientedSuperCursor.cxx @@ -33,7 +33,7 @@ PURPOSE. See the above copyright Nonice for more information. vtkHyperTreeGridNonOrientedSuperCursor* vtkHyperTreeGridNonOrientedSuperCursor::Clone() { vtkHyperTreeGridNonOrientedSuperCursor* clone = this->NewInstance(); - assert("post: clone_exists" && clone != 0); + assert("post: clone_exists" && clone != nullptr); // Copy clone->Grid = this->Grid; clone->CentralCursor->Initialize(this->CentralCursor.Get()); diff --git a/Common/DataModel/vtkHyperTreeGridNonOrientedSuperCursorLight.cxx b/Common/DataModel/vtkHyperTreeGridNonOrientedSuperCursorLight.cxx index 3d5ef94275..7d5caf57f9 100644 --- a/Common/DataModel/vtkHyperTreeGridNonOrientedSuperCursorLight.cxx +++ b/Common/DataModel/vtkHyperTreeGridNonOrientedSuperCursorLight.cxx @@ -30,7 +30,7 @@ PURPOSE. See the above copyright Nonice for more information. vtkHyperTreeGridNonOrientedSuperCursorLight* vtkHyperTreeGridNonOrientedSuperCursorLight::Clone() { vtkHyperTreeGridNonOrientedSuperCursorLight* clone = this->NewInstance(); - assert("post: clone_exists" && clone != 0); + assert("post: clone_exists" && clone != nullptr); // Copy clone->Grid = this->Grid; clone->CentralCursor->Initialize(this->CentralCursor.Get()); diff --git a/Common/DataModel/vtkHyperTreeGridOrientedCursor.cxx b/Common/DataModel/vtkHyperTreeGridOrientedCursor.cxx index e7923698c7..76908edf5a 100644 --- a/Common/DataModel/vtkHyperTreeGridOrientedCursor.cxx +++ b/Common/DataModel/vtkHyperTreeGridOrientedCursor.cxx @@ -29,7 +29,7 @@ vtkHyperTreeGridOrientedCursor* vtkHyperTreeGridOrientedCursor::Clone() { vtkHyperTreeGridOrientedCursor* clone = this->NewInstance(); assert( "post: clone_exists" && - clone != 0 ); + clone != nullptr ); // Copy clone->Grid = this->Grid; clone->Tree = this->Tree; diff --git a/Common/DataModel/vtkHyperTreeGridOrientedGeometryCursor.cxx b/Common/DataModel/vtkHyperTreeGridOrientedGeometryCursor.cxx index 36434613b0..409392d863 100644 --- a/Common/DataModel/vtkHyperTreeGridOrientedGeometryCursor.cxx +++ b/Common/DataModel/vtkHyperTreeGridOrientedGeometryCursor.cxx @@ -29,7 +29,7 @@ vtkHyperTreeGridOrientedGeometryCursor* vtkHyperTreeGridOrientedGeometryCursor:: { vtkHyperTreeGridOrientedGeometryCursor* clone = this->NewInstance(); assert( "post: clone_exists" && - clone != 0 ); + clone != nullptr ); // Copy clone->Grid = this->Grid; clone->Tree = this->Tree; diff --git a/Common/DataModel/vtkHyperTreeGridTools.h b/Common/DataModel/vtkHyperTreeGridTools.h index a7fda0bd5e..f6c9f8c25b 100644 --- a/Common/DataModel/vtkHyperTreeGridTools.h +++ b/Common/DataModel/vtkHyperTreeGridTools.h @@ -24,7 +24,7 @@ namespace hypertreegrid { template < class T > bool HasTree( const T & e ) { - return e.GetTree() != 0; + return e.GetTree() != nullptr; } }// namespace hypertreegrid diff --git a/Common/DataModel/vtkUniformHyperTreeGrid.cxx b/Common/DataModel/vtkUniformHyperTreeGrid.cxx index e9aa0edfd1..622fe17f29 100644 --- a/Common/DataModel/vtkUniformHyperTreeGrid.cxx +++ b/Common/DataModel/vtkUniformHyperTreeGrid.cxx @@ -27,7 +27,7 @@ vtkStandardNewMacro(vtkUniformHyperTreeGrid); // Helper macros to quickly fetch a HT at a given index or iterator #define GetHyperTreeFromOtherMacro(_obj_, _index_) \ (static_cast( \ - _obj_->HyperTrees.find(_index_) != _obj_->HyperTrees.end() ? _obj_->HyperTrees[_index_] : 0)) + _obj_->HyperTrees.find(_index_) != _obj_->HyperTrees.end() ? _obj_->HyperTrees[_index_] : nullptr)) #define GetHyperTreeFromThisMacro(_index_) GetHyperTreeFromOtherMacro(this, _index_) //----------------------------------------------------------------------------- diff --git a/Filters/Core/vtkExplicitStructuredGridCrop.h b/Filters/Core/vtkExplicitStructuredGridCrop.h index 5752d17d55..8df87f0e4f 100644 --- a/Filters/Core/vtkExplicitStructuredGridCrop.h +++ b/Filters/Core/vtkExplicitStructuredGridCrop.h @@ -36,7 +36,7 @@ public: /** * The whole extent of the output has to be set explicitly. */ - void SetOutputWholeExtent(int extent[6], vtkInformation* outInfo = 0); + void SetOutputWholeExtent(int extent[6], vtkInformation* outInfo = nullptr); void SetOutputWholeExtent(int minX, int maxX, int minY, int maxY, int minZ, int maxZ); void GetOutputWholeExtent(int extent[6]); int* GetOutputWholeExtent() { return this->OutputWholeExtent; } diff --git a/Filters/Geometry/vtkExplicitStructuredGridSurfaceFilter.cxx b/Filters/Geometry/vtkExplicitStructuredGridSurfaceFilter.cxx index ae938eacf4..cb776dc8db 100644 --- a/Filters/Geometry/vtkExplicitStructuredGridSurfaceFilter.cxx +++ b/Filters/Geometry/vtkExplicitStructuredGridSurfaceFilter.cxx @@ -28,18 +28,18 @@ vtkExplicitStructuredGridSurfaceFilter::vtkExplicitStructuredGridSurfaceFilter() this->PassThroughCellIds = 0; this->PassThroughPointIds = 0; - this->OriginalCellIdsName = 0; + this->OriginalCellIdsName = nullptr; this->SetOriginalCellIdsName("vtkOriginalCellIds"); - this->OriginalPointIdsName = 0; + this->OriginalPointIdsName = nullptr; this->SetOriginalPointIdsName("vtkOriginalPointIds"); } //---------------------------------------------------------------------------- vtkExplicitStructuredGridSurfaceFilter::~vtkExplicitStructuredGridSurfaceFilter() { - this->SetOriginalCellIdsName(0); - this->SetOriginalPointIdsName(0); + this->SetOriginalCellIdsName(nullptr); + this->SetOriginalPointIdsName(nullptr); } // ---------------------------------------------------------------------------- @@ -130,7 +130,7 @@ int vtkExplicitStructuredGridSurfaceFilter::ExtractSurface( } vtkNew cellIds; - vtkUnsignedCharArray* connectivityFlags = 0; + vtkUnsignedCharArray* connectivityFlags = nullptr; char* facesConnectivityFlagsArrayName = input->GetFacesConnectivityFlagsArrayName(); if (facesConnectivityFlagsArrayName) diff --git a/Filters/Hybrid/vtkAdaptiveDataSetSurfaceFilter.cxx b/Filters/Hybrid/vtkAdaptiveDataSetSurfaceFilter.cxx index bfe3a0d7e5..139801b63f 100644 --- a/Filters/Hybrid/vtkAdaptiveDataSetSurfaceFilter.cxx +++ b/Filters/Hybrid/vtkAdaptiveDataSetSurfaceFilter.cxx @@ -362,7 +362,7 @@ void vtkAdaptiveDataSetSurfaceFilter::ProcessTrees(vtkHyperTreeGrid* input, vtkP } // Retrieve material mask - this->Mask = input->HasMask() ? input->GetMask() : 0; + this->Mask = input->HasMask() ? input->GetMask() : nullptr; // vtkUnsignedCharArray* ghost = nullptr; // DDM input->GetPointGhostArray(); @@ -440,9 +440,9 @@ void vtkAdaptiveDataSetSurfaceFilter::ProcessTrees(vtkHyperTreeGrid* input, vtkP << this->Cells->GetNumberOfConnectivityEntries() << std::endl; this->Points->Delete(); - this->Points = NULL; + this->Points = nullptr; this->Cells->Delete(); - this->Cells = NULL; + this->Cells = nullptr; if (this->Locator) { diff --git a/Filters/HyperTree/vtkHyperTreeGridAxisClip.cxx b/Filters/HyperTree/vtkHyperTreeGridAxisClip.cxx index ef342b7615..1fdc903c7c 100644 --- a/Filters/HyperTree/vtkHyperTreeGridAxisClip.cxx +++ b/Filters/HyperTree/vtkHyperTreeGridAxisClip.cxx @@ -344,7 +344,7 @@ int vtkHyperTreeGridAxisClip::ProcessTrees(vtkHyperTreeGrid* input, vtkDataObjec this->CurrentId = 0; // Retrieve material mask - this->InMask = input->HasMask() ? input->GetMask() : 0; + this->InMask = input->HasMask() ? input->GetMask() : nullptr; // Storage for Cartesian indices unsigned int cart[3]; diff --git a/Filters/HyperTree/vtkHyperTreeGridAxisCut.cxx b/Filters/HyperTree/vtkHyperTreeGridAxisCut.cxx index 5f33d32d48..d4ce96e676 100644 --- a/Filters/HyperTree/vtkHyperTreeGridAxisCut.cxx +++ b/Filters/HyperTree/vtkHyperTreeGridAxisCut.cxx @@ -157,7 +157,7 @@ int vtkHyperTreeGridAxisCut::ProcessTrees( vtkHyperTreeGrid* input, } // Retrieve material mask - this->InMask = this->OutMask ? input->GetMask() : 0; + this->InMask = this->OutMask ? input->GetMask() : nullptr; // Storage for root cell Cartesian coordinates unsigned int i,j,k; diff --git a/Filters/HyperTree/vtkHyperTreeGridAxisReflection.cxx b/Filters/HyperTree/vtkHyperTreeGridAxisReflection.cxx index c21573ad7b..5e22ed29ad 100644 --- a/Filters/HyperTree/vtkHyperTreeGridAxisReflection.cxx +++ b/Filters/HyperTree/vtkHyperTreeGridAxisReflection.cxx @@ -142,7 +142,7 @@ int vtkHyperTreeGridAxisReflection::ProcessTrees(vtkHyperTreeGrid* input, vtkDat } else { - vtkDataArray* inCoords = 0; + vtkDataArray* inCoords = nullptr; unsigned int pmod3 = this->Plane % 3; if (!pmod3) { diff --git a/Filters/HyperTree/vtkHyperTreeGridCellCenters.cxx b/Filters/HyperTree/vtkHyperTreeGridCellCenters.cxx index 749e2c4054..7e70f24765 100644 --- a/Filters/HyperTree/vtkHyperTreeGridCellCenters.cxx +++ b/Filters/HyperTree/vtkHyperTreeGridCellCenters.cxx @@ -160,7 +160,7 @@ void vtkHyperTreeGridCellCenters::ProcessTrees() this->Points = vtkPoints::New(); // Retrieve material mask - this->InMask = this->Input->HasMask() ? this->Input->GetMask() : 0; + this->InMask = this->Input->HasMask() ? this->Input->GetMask() : nullptr; // Iterate over all hyper trees vtkIdType index; diff --git a/Filters/HyperTree/vtkHyperTreeGridContour.cxx b/Filters/HyperTree/vtkHyperTreeGridContour.cxx index c700627a76..61079a67cc 100644 --- a/Filters/HyperTree/vtkHyperTreeGridContour.cxx +++ b/Filters/HyperTree/vtkHyperTreeGridContour.cxx @@ -288,7 +288,7 @@ int vtkHyperTreeGridContour::ProcessTrees( vtkHyperTreeGrid* input, this->CurrentId = 0; // Retrieve material mask - this->InMask = input->HasMask() ? input->GetMask() : 0; + this->InMask = input->HasMask() ? input->GetMask() : nullptr; // Estimate output size as a multiple of 1024 vtkIdType numCells = input->GetNumberOfVertices(); diff --git a/Filters/HyperTree/vtkHyperTreeGridEvaluateCoarse.cxx b/Filters/HyperTree/vtkHyperTreeGridEvaluateCoarse.cxx index 759c262089..7d30a40d1d 100644 --- a/Filters/HyperTree/vtkHyperTreeGridEvaluateCoarse.cxx +++ b/Filters/HyperTree/vtkHyperTreeGridEvaluateCoarse.cxx @@ -33,7 +33,7 @@ vtkStandardNewMacro(vtkHyperTreeGridEvaluateCoarse); vtkHyperTreeGridEvaluateCoarse::vtkHyperTreeGridEvaluateCoarse() { this->Operator = vtkHyperTreeGridEvaluateCoarse::OPERATOR_DON_T_CHANGE; - this->Mask = 0; + this->Mask = nullptr; this->Default = 0.; @@ -83,7 +83,7 @@ int vtkHyperTreeGridEvaluateCoarse::ProcessTrees( vtkHyperTreeGrid* input, return 1; } - this->Mask = output->HasMask() ? output->GetMask() : 0; + this->Mask = output->HasMask() ? output->GetMask() : nullptr; this->BranchFactor = output->GetBranchFactor(); this->Dimension = output->GetDimension(); diff --git a/Filters/HyperTree/vtkHyperTreeGridGeometry.cxx b/Filters/HyperTree/vtkHyperTreeGridGeometry.cxx index 7c30c459e5..ee020e89d4 100644 --- a/Filters/HyperTree/vtkHyperTreeGridGeometry.cxx +++ b/Filters/HyperTree/vtkHyperTreeGridGeometry.cxx @@ -383,12 +383,12 @@ int vtkHyperTreeGridGeometry::ProcessTrees( vtkHyperTreeGrid* input, if ( this->Points ) { this->Points->Delete(); - this->Points = NULL; + this->Points = nullptr; } if ( this->Cells ) { this->Cells->Delete(); - this->Cells = NULL; + this->Cells = nullptr; } if ( this->Locator ) @@ -517,7 +517,7 @@ void vtkHyperTreeGridGeometry::RecursivelyProcessTree3D( //FR Parce que le curseur est un super curseur bool pureMask = false; - if ( this->Mask != 0 ) + if ( this->Mask != nullptr ) { // JB Question : que fait le PureMaterialMask quand un masque est mis sur un coarse et pas toutes les filles pureMask = this->PureMask->GetValue( cursor->GetGlobalNodeIndex() ) != 0 ; diff --git a/Filters/Modeling/vtkCollisionDetectionFilter.cxx b/Filters/Modeling/vtkCollisionDetectionFilter.cxx index a81443d286..56c9570e5c 100644 --- a/Filters/Modeling/vtkCollisionDetectionFilter.cxx +++ b/Filters/Modeling/vtkCollisionDetectionFilter.cxx @@ -146,7 +146,7 @@ void vtkCollisionDetectionFilter::SetInputData(int idx, vtkPolyData *input) vtkSmartPointer inputProducer = vtkSmartPointer::New(); inputProducer->SetOutput(input); - this->SetNthInputConnection(idx, 0, input ? inputProducer->GetOutputPort() : 0); + this->SetNthInputConnection(idx, 0, input ? inputProducer->GetOutputPort() : nullptr); } //---------------------------------------------------------------------------- diff --git a/IO/Exodus/vtkExodusIIReader.cxx b/IO/Exodus/vtkExodusIIReader.cxx index c47d109a98..6e55f8983b 100644 --- a/IO/Exodus/vtkExodusIIReader.cxx +++ b/IO/Exodus/vtkExodusIIReader.cxx @@ -5389,7 +5389,7 @@ vtkMTimeType vtkExodusIIReader::GetMetadataMTime() } \ else \ { \ - this->propName = 0; \ + this->propName = nullptr; \ } void vtkExodusIIReader::SetFileName( const char* fname ) diff --git a/IO/ParallelExodus/vtkPExodusIIReader.cxx b/IO/ParallelExodus/vtkPExodusIIReader.cxx index 620dd2c738..c640639d7e 100644 --- a/IO/ParallelExodus/vtkPExodusIIReader.cxx +++ b/IO/ParallelExodus/vtkPExodusIIReader.cxx @@ -144,12 +144,12 @@ vtkPExodusIIReader::vtkPExodusIIReader() this->ProcRank = 0; this->ProcSize = 1; // NB. SetController will initialize ProcSize and ProcRank - this->Controller = 0; + this->Controller = nullptr; this->SetController( vtkMultiProcessController::GetGlobalController() ); - this->FilePattern = 0; - this->CurrentFilePattern = 0; - this->FilePrefix = 0; - this->CurrentFilePrefix = 0; + this->FilePattern = nullptr; + this->CurrentFilePattern = nullptr; + this->FilePrefix = nullptr; + this->CurrentFilePrefix = nullptr; this->FileRange[0] = -1; this->FileRange[1] = -1; this->CurrentFileRange[0] = 0; @@ -166,9 +166,9 @@ vtkPExodusIIReader::vtkPExodusIIReader() //---------------------------------------------------------------------------- vtkPExodusIIReader::~vtkPExodusIIReader() { - this->SetController( 0 ); - this->SetFilePattern( 0 ); - this->SetFilePrefix( 0 ); + this->SetController( nullptr ); + this->SetFilePattern( nullptr ); + this->SetFilePrefix( nullptr ); // If we've allocated filenames then delete them if ( this->FileNames ) @@ -1148,7 +1148,7 @@ static void BroadcastBlockSetInfo( vtkMultiProcessController* controller, { bsinfo->CachedConnectivity->Delete(); } - bsinfo->CachedConnectivity = 0; + bsinfo->CachedConnectivity = nullptr; bsinfo->PointMap.clear(); bsinfo->ReversePointMap.clear(); controller->Broadcast( &len, 1, 0 ); @@ -1522,8 +1522,8 @@ void vtkPExodusIIReader::Broadcast( vtkMultiProcessController* ctrl ) delete [] this->FilePrefix; //this->SetFilePattern( BroadcastRecvString( ctrl, tmp ) ? &tmp[0] : 0 ); // XXX Bad set //this->SetFilePrefix( BroadcastRecvString( ctrl, tmp ) ? &tmp[0] : 0 ); // XXX Bad set - this->FilePattern = BroadcastRecvString( ctrl, tmp ) ? vtksys::SystemTools::DuplicateString( &tmp[0] ) : 0; - this->FilePrefix = BroadcastRecvString( ctrl, tmp ) ? vtksys::SystemTools::DuplicateString( &tmp[0] ) : 0; + this->FilePattern = BroadcastRecvString( ctrl, tmp ) ? vtksys::SystemTools::DuplicateString( &tmp[0] ) : nullptr; + this->FilePrefix = BroadcastRecvString( ctrl, tmp ) ? vtksys::SystemTools::DuplicateString( &tmp[0] ) : nullptr; } ctrl->Broadcast( this->FileRange, 2, 0 ); ctrl->Broadcast( &this->NumberOfFiles, 1, 0 ); diff --git a/Rendering/Volume/vtkFixedPointVolumeRayCastHelper.h b/Rendering/Volume/vtkFixedPointVolumeRayCastHelper.h index af893a2292..cbf40b140d 100644 --- a/Rendering/Volume/vtkFixedPointVolumeRayCastHelper.h +++ b/Rendering/Volume/vtkFixedPointVolumeRayCastHelper.h @@ -936,7 +936,7 @@ unsigned short tmp[4]; #define VTKKWRCHelper_InitializeCompositeOneGOTrilin() \ - unsigned char *magPtrABCD = 0, *magPtrEFGH = 0; \ + unsigned char *magPtrABCD = nullptr, *magPtrEFGH = nullptr; \ unsigned short mag; \ unsigned int mA=0,mB=0,mC=0,mD=0,mE=0,mF=0,mG=0,mH=0; diff --git a/Testing/Core/vtkTestConditionals.txx b/Testing/Core/vtkTestConditionals.txx index cc4920fe7b..792dbe4129 100644 --- a/Testing/Core/vtkTestConditionals.txx +++ b/Testing/Core/vtkTestConditionals.txx @@ -88,7 +88,7 @@ inline bool testNotNull(const T& a, const std::string& msg) { std::cout << msg << ": "; } - if (a != NULL) + if (a != nullptr) { if (print) { diff --git a/Utilities/DICOMParser/DICOMParser.cxx b/Utilities/DICOMParser/DICOMParser.cxx index eb94cf4589..ed44b31707 100644 --- a/Utilities/DICOMParser/DICOMParser.cxx +++ b/Utilities/DICOMParser/DICOMParser.cxx @@ -125,7 +125,7 @@ void DICOMParser::CloseFile() { // Deleting the DataFile closes any previously opened file delete this->DataFile; - this->DataFile = 0; + this->DataFile = nullptr; } DICOMParser::~DICOMParser() { -- GitLab