Merge pull request #1588 from rohit-n/zero-nullptr

Silence a few "zero as null pointer" warnings.
This commit is contained in:
Lioncash 2014-11-24 19:26:55 -05:00
commit 8b337120db
4 changed files with 5 additions and 5 deletions

View File

@ -348,7 +348,7 @@ protected:
inline void Write32(u32 value) {*(u32*)code = value; code+=4;} inline void Write32(u32 value) {*(u32*)code = value; code+=4;}
public: public:
ARMXEmitter() : code(0), startcode(0), lastCacheFlushEnd(0) { ARMXEmitter() : code(nullptr), startcode(nullptr), lastCacheFlushEnd(nullptr) {
condition = CC_AL << 28; condition = CC_AL << 28;
} }
ARMXEmitter(u8 *code_ptr) { ARMXEmitter(u8 *code_ptr) {

View File

@ -2285,7 +2285,7 @@ const char* GekkoDisassembler::GetGPRName(u32 index)
if (index < 32) if (index < 32)
return gprnames[index]; return gprnames[index];
return 0; return nullptr;
} }
static const char* fprnames[] = static const char* fprnames[] =
@ -2301,5 +2301,5 @@ const char* GekkoDisassembler::GetFPRName(u32 index)
if (index < 32) if (index < 32)
return fprnames[index]; return fprnames[index];
return 0; return nullptr;
} }

View File

@ -9,7 +9,7 @@ using namespace ArmGen;
ArmFPRCache::ArmFPRCache() ArmFPRCache::ArmFPRCache()
{ {
emit = 0; emit = nullptr;
} }
void ArmFPRCache::Init(ARMXEmitter *emitter) void ArmFPRCache::Init(ARMXEmitter *emitter)

View File

@ -9,7 +9,7 @@ using namespace ArmGen;
ArmRegCache::ArmRegCache() ArmRegCache::ArmRegCache()
{ {
emit = 0; emit = nullptr;
} }
void ArmRegCache::Init(ARMXEmitter *emitter) void ArmRegCache::Init(ARMXEmitter *emitter)