summaryrefslogtreecommitdiff
path: root/src/company_base.h
diff options
context:
space:
mode:
authorHenry Wilson <m3henry@googlemail.com>2019-04-10 22:07:06 +0100
committerMichael Lutz <michi@icosahedron.de>2019-04-10 23:22:20 +0200
commit7c8e7c6b6e16d4a26259a676db32d8776b99817e (patch)
tree99f134b7e66367cf11e10bc5061896eab4a3264f /src/company_base.h
parent3b4f224c0bc50e7248050d4bcbb6d83fd510c1cc (diff)
downloadopenttd-7c8e7c6b6e16d4a26259a676db32d8776b99817e.tar.xz
Codechange: Use null pointer literal instead of the NULL macro
Diffstat (limited to 'src/company_base.h')
-rw-r--r--src/company_base.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/company_base.h b/src/company_base.h
index 9d2bc9000..309130f59 100644
--- a/src/company_base.h
+++ b/src/company_base.h
@@ -98,7 +98,7 @@ struct CompanyProperties {
// TODO: Change some of these member variables to use relevant INVALID_xxx constants
CompanyProperties()
- : name_2(0), name_1(0), name(NULL), president_name_1(0), president_name_2(0), president_name(NULL),
+ : name_2(0), name_1(0), name(nullptr), president_name_1(0), president_name_2(0), president_name(nullptr),
face(0), money(0), money_fraction(0), current_loan(0), colour(0), block_preview(0),
location_of_HQ(0), last_build_coordinate(0), share_owners(), inaugurated_year(0),
months_of_bankruptcy(0), bankrupt_asked(0), bankrupt_timeout(0), bankrupt_value(0),
@@ -137,7 +137,7 @@ struct Company : CompanyPool::PoolItem<&_company_pool>, CompanyProperties {
static inline bool IsValidAiID(size_t index)
{
const Company *c = Company::GetIfValid(index);
- return c != NULL && c->is_ai;
+ return c != nullptr && c->is_ai;
}
/**
@@ -149,7 +149,7 @@ struct Company : CompanyPool::PoolItem<&_company_pool>, CompanyProperties {
static inline bool IsValidHumanID(size_t index)
{
const Company *c = Company::GetIfValid(index);
- return c != NULL && !c->is_ai;
+ return c != nullptr && !c->is_ai;
}
/**