T2345: Replace instances of NULL with nullptr
The following changes have been applied to src and lib folders: regex replace: ([^"_])NULL ⇒ \1nullptr (8968 chgs in src, 1153 in lib) Manually find/change: (void \*) nullptr ⇒ nullptr (1 case) regex find: ".*?nullptr.*?" Manually ~14 cases back to "NULL" in src, ~2 in lib regex finds a few false positive where nullptr appears between two strings in a function call
This commit is contained in:
@ -74,7 +74,7 @@ void Set::command(int narg, char **arg)
|
||||
int n = strlen(arg[1]) + 1;
|
||||
id = new char[n];
|
||||
strcpy(id,arg[1]);
|
||||
select = NULL;
|
||||
select = nullptr;
|
||||
selection(atom->nlocal);
|
||||
|
||||
// loop over keyword/value pairs
|
||||
@ -689,7 +689,7 @@ void Set::set(int keyword)
|
||||
{
|
||||
// evaluate atom-style variable(s) if necessary
|
||||
|
||||
vec1 = vec2 = vec3 = vec4 = NULL;
|
||||
vec1 = vec2 = vec3 = vec4 = nullptr;
|
||||
|
||||
if (varflag) {
|
||||
int nlocal = atom->nlocal;
|
||||
@ -907,7 +907,7 @@ void Set::set(int keyword)
|
||||
// enforce quat rotation vector in z dir for 2d systems
|
||||
|
||||
else if (keyword == QUAT) {
|
||||
double *quat = NULL;
|
||||
double *quat = nullptr;
|
||||
if (avec_ellipsoid && atom->ellipsoid[i] >= 0)
|
||||
quat = avec_ellipsoid->bonus[atom->ellipsoid[i]].quat;
|
||||
else if (avec_tri && atom->tri[i] >= 0)
|
||||
|
||||
Reference in New Issue
Block a user