Skip to content

Commit 18d3bdf

Browse files
committed
refactor: comment out NULL definitions, use nullptr instead
1 parent dc0cd0a commit 18d3bdf

File tree

12 files changed

+22
-12
lines changed

12 files changed

+22
-12
lines changed

Core/Libraries/Include/Lib/BaseTypeCore.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,8 @@
9090

9191
#ifndef NULL
9292
//#define NULL ((void *)0)
93-
#define NULL 0 // C++ doesn't like casting void *'s into other pointers
93+
//#define NULL 0 // C++ doesn't like casting void *'s into other pointers
94+
// NULL is now deprecated - use nullptr instead
9495
#endif
9596

9697
// MSVC math.h defines overloaded functions with this name...

Core/Libraries/Source/WWVegas/WWLib/HASHLIST.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,8 @@
5252
#include <memory.h>
5353

5454
#ifndef NULL
55-
#define NULL (0L)
55+
//#define NULL (0L)
56+
// NULL is now deprecated - use nullptr instead
5657
#endif
5758

5859
#define A_LARGE_PRIME_NUMBER 257

Core/Libraries/Source/WWVegas/WWLib/INI.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,8 @@ template<class T> class List;
6565
template<class T, class U> class IndexClass;
6666

6767
#ifndef NULL
68-
#define NULL 0L
68+
//#define NULL 0L
69+
// NULL is now deprecated - use nullptr instead
6970
#endif
7071

7172
/*

Core/Libraries/Source/WWVegas/WWLib/SLIST.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,8 @@
5757
#include "SLNODE.h"
5858

5959
#ifndef NULL
60-
#define NULL 0L
60+
//#define NULL 0L
61+
// NULL is now deprecated - use nullptr instead
6162
#endif
6263

6364
template <class T>

Core/Libraries/Source/WWVegas/WWLib/SLNODE.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,8 @@
3838
#include "mempool.h"
3939

4040
#ifndef NULL
41-
#define NULL 0
41+
//#define NULL 0
42+
// NULL is now deprecated - use nullptr instead
4243
#endif
4344

4445
// Forward references for friend classes

Core/Libraries/Source/WWVegas/WWLib/WWFILE.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050
#endif
5151

5252
#ifndef NULL
53-
#define NULL 0
53+
//#define NULL 0
54+
// NULL is now deprecated - use nullptr instead
5455
#endif
5556

5657

Core/Libraries/Source/WWVegas/WWLib/always.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,8 @@ template <class T> T max(T a,T b)
256256

257257

258258
#ifndef NULL
259-
#define NULL 0
259+
//#define NULL 0
260+
// NULL is now deprecated - use nullptr instead
260261
#endif
261262

262263

Core/Tools/Launcher/Toolkit/Support/UTypes.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,5 +87,6 @@ typedef enum {OFF = false, ON = true, PENDING = -1} TriState;
8787

8888
//! Empty pointer
8989
#ifndef NULL
90-
#define NULL (0L)
90+
//#define NULL (0L)
91+
// NULL is now deprecated - use nullptr instead
9192
#endif

Core/Tools/Launcher/wstypes.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,8 @@ Standard type definitions for the sake of portability and readability.
4747
#endif
4848

4949
#ifndef NULL
50-
#define NULL 0
50+
//#define NULL 0
51+
// NULL is now deprecated - use nullptr instead
5152
#endif
5253

5354
//These are used for readability purposes mostly, when a method takes a

Core/Tools/mangler/wlib/wstypes.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,8 @@ Standard type definitions for the sake of portability and readability.
7373
#endif
7474

7575
#ifndef NULL
76-
#define NULL 0
76+
//#define NULL 0
77+
// NULL is now deprecated - use nullptr instead
7778
#endif
7879

7980
//These are used for readability purposes mostly, when a method takes a

0 commit comments

Comments
 (0)