summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/machine
diff options
context:
space:
mode:
author Miodrag Milanovic <mmicko@gmail.com>2015-12-04 07:03:38 +0100
committer Miodrag Milanovic <mmicko@gmail.com>2015-12-04 07:03:38 +0100
commit41681c1703244abe68cbcf3096ca259bd061cc08 (patch)
tree85d24789ff864e1b0f35fb87f0c58bad5925e27d /src/mame/machine
parent0c56ac848dd0eba359500d444ecbb51f215ff5b9 (diff)
clang-modernize part 4
Diffstat (limited to 'src/mame/machine')
-rw-r--r--src/mame/machine/315-5881_crypt.cpp2
-rw-r--r--src/mame/machine/6883sam.cpp14
-rw-r--r--src/mame/machine/6883sam.h2
-rw-r--r--src/mame/machine/abc1600mac.cpp4
-rw-r--r--src/mame/machine/amiga.cpp6
-rw-r--r--src/mame/machine/amigakbd.cpp12
-rw-r--r--src/mame/machine/amstrad.cpp52
-rw-r--r--src/mame/machine/apollo.cpp8
-rw-r--r--src/mame/machine/apollo_dbg.cpp516
-rw-r--r--src/mame/machine/apollo_kbd.cpp10
-rw-r--r--src/mame/machine/appldriv.cpp16
-rw-r--r--src/mame/machine/apple2.cpp66
-rw-r--r--src/mame/machine/apple2gs.cpp14
-rw-r--r--src/mame/machine/apple3.cpp26
-rw-r--r--src/mame/machine/applefdc.cpp18
-rw-r--r--src/mame/machine/apricotkb_hle.cpp60
-rw-r--r--src/mame/machine/archimds.cpp8
-rw-r--r--src/mame/machine/asic65.cpp2
-rw-r--r--src/mame/machine/asteroid.cpp4
-rw-r--r--src/mame/machine/atarifdc.cpp6
-rw-r--r--src/mame/machine/atarigen.cpp46
-rw-r--r--src/mame/machine/awboard.cpp4
-rw-r--r--src/mame/machine/b2m.cpp2
-rw-r--r--src/mame/machine/balsente.cpp2
-rw-r--r--src/mame/machine/bbc.cpp8
-rw-r--r--src/mame/machine/bebox.cpp10
-rw-r--r--src/mame/machine/bublbobl.cpp2
-rw-r--r--src/mame/machine/c117.cpp4
-rw-r--r--src/mame/machine/c117.h2
-rw-r--r--src/mame/machine/coco.cpp106
-rw-r--r--src/mame/machine/coco_vhd.h4
-rw-r--r--src/mame/machine/cps2crpt.cpp8
-rw-r--r--src/mame/machine/cuda.cpp4
-rw-r--r--src/mame/machine/dc-ctrl.cpp12
-rw-r--r--src/mame/machine/decocass_tape.cpp6
-rw-r--r--src/mame/machine/dgn_beta.cpp128
-rw-r--r--src/mame/machine/dgnalpha.cpp2
-rw-r--r--src/mame/machine/egret.cpp2
-rw-r--r--src/mame/machine/electron.cpp2
-rw-r--r--src/mame/machine/fd1089.cpp4
-rw-r--r--src/mame/machine/fd1094.cpp12
-rw-r--r--src/mame/machine/gaelco3d.cpp12
-rw-r--r--src/mame/machine/gamecom.cpp4
-rw-r--r--src/mame/machine/gdrom.cpp4
-rw-r--r--src/mame/machine/genpin.h2
-rw-r--r--src/mame/machine/harddriv.cpp18
-rw-r--r--src/mame/machine/hec2hrp.cpp2
-rw-r--r--src/mame/machine/hp48.cpp6
-rw-r--r--src/mame/machine/igs022.cpp2
-rw-r--r--src/mame/machine/igs028.cpp2
-rw-r--r--src/mame/machine/inder_sb.cpp2
-rw-r--r--src/mame/machine/isbc_215g.cpp6
-rw-r--r--src/mame/machine/iteagle_fpga.cpp6
-rw-r--r--src/mame/machine/kaneko_calc3.cpp2
-rw-r--r--src/mame/machine/kaypro.cpp4
-rw-r--r--src/mame/machine/kc.cpp2
-rw-r--r--src/mame/machine/konppc.cpp8
-rw-r--r--src/mame/machine/lynx.cpp6
-rw-r--r--src/mame/machine/mac.cpp10
-rw-r--r--src/mame/machine/maple-dc.cpp4
-rw-r--r--src/mame/machine/mapledev.cpp2
-rw-r--r--src/mame/machine/mbc55x.cpp4
-rw-r--r--src/mame/machine/mbee.cpp2
-rw-r--r--src/mame/machine/mcr.cpp4
-rw-r--r--src/mame/machine/megacdcd.cpp26
-rw-r--r--src/mame/machine/mexico86.cpp2
-rw-r--r--src/mame/machine/mhavoc.cpp2
-rw-r--r--src/mame/machine/microdrv.h2
-rw-r--r--src/mame/machine/micropolis.cpp4
-rw-r--r--src/mame/machine/microtan.cpp4
-rw-r--r--src/mame/machine/midwayic.cpp20
-rw-r--r--src/mame/machine/mie.cpp8
-rw-r--r--src/mame/machine/mm1kb.cpp2
-rw-r--r--src/mame/machine/model1.cpp100
-rw-r--r--src/mame/machine/msx.cpp2
-rw-r--r--src/mame/machine/mtx.cpp2
-rw-r--r--src/mame/machine/n64.cpp8
-rw-r--r--src/mame/machine/namco51.cpp2
-rw-r--r--src/mame/machine/namcos2.cpp10
-rw-r--r--src/mame/machine/naomibd.cpp8
-rw-r--r--src/mame/machine/naomigd.cpp6
-rw-r--r--src/mame/machine/naomim1.cpp4
-rw-r--r--src/mame/machine/naomim4.cpp6
-rw-r--r--src/mame/machine/nb1414m4.cpp2
-rw-r--r--src/mame/machine/ng_memcard.h2
-rw-r--r--src/mame/machine/nmk112.cpp8
-rw-r--r--src/mame/machine/osborne1.cpp2
-rw-r--r--src/mame/machine/pce220_ser.h4
-rw-r--r--src/mame/machine/pk8020.cpp2
-rw-r--r--src/mame/machine/playch10.cpp22
-rw-r--r--src/mame/machine/pmd85.cpp4
-rw-r--r--src/mame/machine/prof80mmu.cpp2
-rw-r--r--src/mame/machine/psion_pack.cpp6
-rw-r--r--src/mame/machine/psxcd.cpp44
-rw-r--r--src/mame/machine/psxcd.h4
-rw-r--r--src/mame/machine/rm380z.cpp2
-rw-r--r--src/mame/machine/rmnimbus.cpp14
-rw-r--r--src/mame/machine/rx01.cpp2
-rw-r--r--src/mame/machine/samcoupe.cpp14
-rw-r--r--src/mame/machine/scramble.cpp2
-rw-r--r--src/mame/machine/segaic16.cpp46
-rw-r--r--src/mame/machine/segaic16.h4
-rw-r--r--src/mame/machine/seicop.cpp2
-rw-r--r--src/mame/machine/sgi.cpp2
-rw-r--r--src/mame/machine/slapstic.cpp2
-rw-r--r--src/mame/machine/smartmed.cpp12
-rw-r--r--src/mame/machine/smartmed.h2
-rw-r--r--src/mame/machine/sms.cpp6
-rw-r--r--src/mame/machine/sonydriv.cpp8
-rw-r--r--src/mame/machine/special.cpp2
-rw-r--r--src/mame/machine/st0016.cpp2
-rw-r--r--src/mame/machine/super80.cpp2
-rw-r--r--src/mame/machine/svi318.cpp4
-rw-r--r--src/mame/machine/swtpc09.cpp6
-rw-r--r--src/mame/machine/tait8741.cpp2
-rw-r--r--src/mame/machine/taitosj.cpp2
-rw-r--r--src/mame/machine/thomflop.cpp10
-rw-r--r--src/mame/machine/thomson.cpp10
-rw-r--r--src/mame/machine/ticket.cpp2
-rw-r--r--src/mame/machine/tnzs.cpp2
-rw-r--r--src/mame/machine/trs80.cpp4
-rw-r--r--src/mame/machine/vector06.cpp2
-rw-r--r--src/mame/machine/volfied.cpp2
-rw-r--r--src/mame/machine/vsnes.cpp2
-rw-r--r--src/mame/machine/vtech2.cpp4
-rw-r--r--src/mame/machine/wpc_lamp.cpp2
-rw-r--r--src/mame/machine/wpc_out.cpp2
-rw-r--r--src/mame/machine/x68k_hdc.h4
-rw-r--r--src/mame/machine/xbox.cpp10
-rw-r--r--src/mame/machine/z80ne.cpp2
-rw-r--r--src/mame/machine/zs01.cpp2
-rw-r--r--src/mame/machine/zx8302.cpp2
132 files changed, 925 insertions, 925 deletions
diff --git a/src/mame/machine/315-5881_crypt.cpp b/src/mame/machine/315-5881_crypt.cpp
index ec07d1c8380..96f654a44e1 100644
--- a/src/mame/machine/315-5881_crypt.cpp
+++ b/src/mame/machine/315-5881_crypt.cpp
@@ -49,7 +49,7 @@ void sega_315_5881_crypt_device::device_start()
std::string skey = parameter("key");
if(!skey.empty())
- key = strtoll(skey.c_str(), 0, 16);
+ key = strtoll(skey.c_str(), nullptr, 16);
else
{
logerror("%s: Warning: key not provided\n", tag());
diff --git a/src/mame/machine/6883sam.cpp b/src/mame/machine/6883sam.cpp
index d47fe3efe78..d912d65ea90 100644
--- a/src/mame/machine/6883sam.cpp
+++ b/src/mame/machine/6883sam.cpp
@@ -72,7 +72,7 @@ const device_type SAM6883 = &device_creator<sam6883_device>;
sam6883_device::sam6883_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: device_t(mconfig, SAM6883, "SAM6883", tag, owner, clock, "sam6883", __FILE__),
- m_cpu_tag(NULL),
+ m_cpu_tag(nullptr),
m_cpu_space_ref(AS_PROGRAM),
m_read_res(*this),
m_space_0000(*this),
@@ -133,7 +133,7 @@ void sam6883_device::configure_bank(int bank, UINT8 *memory, UINT32 memory_size,
void sam6883_device::configure_bank(int bank, read8_delegate rhandler, write8_delegate whandler)
{
- configure_bank(bank, NULL, 0, false, rhandler, whandler);
+ configure_bank(bank, nullptr, 0, false, rhandler, whandler);
}
@@ -454,8 +454,8 @@ template<UINT16 _addrstart, UINT16 _addrend>
sam6883_device::sam_space<_addrstart, _addrend>::sam_space(sam6883_device &owner)
: m_owner(owner)
{
- m_read_bank = NULL;
- m_write_bank = NULL;
+ m_read_bank = nullptr;
+ m_write_bank = nullptr;
m_mask = 0;
}
@@ -468,7 +468,7 @@ sam6883_device::sam_space<_addrstart, _addrend>::sam_space(sam6883_device &owner
template<UINT16 _addrstart, UINT16 _addrend>
address_space &sam6883_device::sam_space<_addrstart, _addrend>::cpu_space() const
{
- assert(m_owner.m_cpu_space != NULL);
+ assert(m_owner.m_cpu_space != nullptr);
return *m_owner.m_cpu_space;
}
@@ -506,7 +506,7 @@ void sam6883_device::sam_space<_addrstart, _addrend>::point_specific_bank(const
{
char buffer[16];
- if (bank->m_memory != NULL)
+ if (bank->m_memory != nullptr)
{
// normalize offset
if (mask != 0)
@@ -530,7 +530,7 @@ void sam6883_device::sam_space<_addrstart, _addrend>::point_specific_bank(const
}
// point the bank
- if (memory_bank != NULL)
+ if (memory_bank != nullptr)
{
if (is_write && bank->m_memory_read_only)
memory_bank->set_base(m_owner.m_dummy);
diff --git a/src/mame/machine/6883sam.h b/src/mame/machine/6883sam.h
index 772fe38d63f..d559860d313 100644
--- a/src/mame/machine/6883sam.h
+++ b/src/mame/machine/6883sam.h
@@ -31,7 +31,7 @@
class sam6883_friend_device
{
public:
- sam6883_friend_device() { m_cpu = NULL; m_sam_state = 0x0000; }
+ sam6883_friend_device() { m_cpu = nullptr; m_sam_state = 0x0000; }
protected:
// SAM state constants
diff --git a/src/mame/machine/abc1600mac.cpp b/src/mame/machine/abc1600mac.cpp
index b22f55708c6..07cc653fc2e 100644
--- a/src/mame/machine/abc1600mac.cpp
+++ b/src/mame/machine/abc1600mac.cpp
@@ -125,7 +125,7 @@ void abc1600_mac_device::device_start()
{
// get the CPU device
m_cpu = machine().device<m68000_base_device>(m_cpu_tag);
- assert(m_cpu != NULL);
+ assert(m_cpu != nullptr);
// allocate memory
m_segment_ram.allocate(0x400);
@@ -160,7 +160,7 @@ void abc1600_mac_device::device_reset()
const address_space_config *abc1600_mac_device::memory_space_config(address_spacenum spacenum) const
{
- return (spacenum == AS_PROGRAM) ? &m_space_config : NULL;
+ return (spacenum == AS_PROGRAM) ? &m_space_config : nullptr;
}
diff --git a/src/mame/machine/amiga.cpp b/src/mame/machine/amiga.cpp
index 6d9fcf46844..47b1d49c33f 100644
--- a/src/mame/machine/amiga.cpp
+++ b/src/mame/machine/amiga.cpp
@@ -147,7 +147,7 @@ void amiga_state::machine_start()
// set up chip RAM access
memory_share *share = memshare("chip_ram");
- if (share == NULL)
+ if (share == nullptr)
fatalerror("Unable to find Amiga chip RAM\n");
m_chip_ram.set(*share, 2);
m_chip_ram_mask = (m_chip_ram.bytes() - 1) & ~1;
@@ -380,7 +380,7 @@ TIMER_CALLBACK_MEMBER( amiga_state::amiga_irq_proc )
UINT16 amiga_state::joy0dat_r()
{
- if (m_input_device == NULL)
+ if (m_input_device == nullptr)
return m_joy0dat_port ? m_joy0dat_port->read() : 0xffff;
if (m_input_device->read() & 0x10)
@@ -391,7 +391,7 @@ UINT16 amiga_state::joy0dat_r()
UINT16 amiga_state::joy1dat_r()
{
- if (m_input_device == NULL)
+ if (m_input_device == nullptr)
return m_joy1dat_port ? m_joy1dat_port->read() : 0xffff;
if (m_input_device->read() & 0x20)
diff --git a/src/mame/machine/amigakbd.cpp b/src/mame/machine/amigakbd.cpp
index c6d1bb05d34..1120c522e6c 100644
--- a/src/mame/machine/amigakbd.cpp
+++ b/src/mame/machine/amigakbd.cpp
@@ -282,9 +282,9 @@ amigakbd_device::amigakbd_device(const machine_config &mconfig, const char *tag,
m_row_c2(*this, "row_c2"),
m_row_c1(*this, "row_c1"),
m_row_c0(*this, "row_c0"),
- m_timer(NULL),
- m_watchdog(NULL),
- m_reset(NULL),
+ m_timer(nullptr),
+ m_watchdog(nullptr),
+ m_reset(nullptr),
m_kdat(1),
m_kclk(1),
m_port_c(0xff),
@@ -307,9 +307,9 @@ void amigakbd_device::device_start()
m_write_krst.resolve_safe();
// allocate timers
- m_timer = timer_alloc(0, NULL);
- m_watchdog = timer_alloc(1, NULL);
- m_reset = timer_alloc(2, NULL);
+ m_timer = timer_alloc(0, nullptr);
+ m_watchdog = timer_alloc(1, nullptr);
+ m_reset = timer_alloc(2, nullptr);
// register for save states
save_item(NAME(m_kdat));
diff --git a/src/mame/machine/amstrad.cpp b/src/mame/machine/amstrad.cpp
index ed4a3f04d6b..eed5c0f291e 100644
--- a/src/mame/machine/amstrad.cpp
+++ b/src/mame/machine/amstrad.cpp
@@ -689,7 +689,7 @@ void amstrad_state::amstrad_update_video()
m_gate_array.line_ticks++;
if ( m_gate_array.line_ticks > m_gate_array.bitmap->width() )
{
- m_gate_array.draw_p = NULL;
+ m_gate_array.draw_p = nullptr;
cycles_passed = 0;
}
}
@@ -791,7 +791,7 @@ void amstrad_state::amstrad_plus_update_video()
m_asic.hsync_first_tick = false;
if ( m_gate_array.line_ticks >= m_gate_array.bitmap->width() )
{
- m_gate_array.draw_p = NULL;
+ m_gate_array.draw_p = nullptr;
cycles_passed = 0;
}
}
@@ -872,7 +872,7 @@ WRITE_LINE_MEMBER(amstrad_state::amstrad_hsync_changed)
}
else
{
- m_gate_array.draw_p = NULL;
+ m_gate_array.draw_p = nullptr;
}
if ( m_gate_array.hsync_after_vsync_counter != 0 ) // counters still operate regardless of PRI state
@@ -915,7 +915,7 @@ WRITE_LINE_MEMBER(amstrad_state::amstrad_plus_hsync_changed)
}
else
{
- m_gate_array.draw_p = NULL;
+ m_gate_array.draw_p = nullptr;
}
if ( m_gate_array.hsync_after_vsync_counter != 0 ) // counters still operate regardless of PRI state
@@ -1106,24 +1106,24 @@ static device_t* get_expansion_device(running_machine &machine, const char* tag)
amstrad_state *state = machine.driver_data<amstrad_state>();
cpc_expansion_slot_device* exp_port = state->m_exp;
- while(exp_port != NULL)
+ while(exp_port != nullptr)
{
device_t* temp;
// first, check if this expansion port has the device we want attached
temp = exp_port->subdevice(tag);
- if(temp != NULL)
+ if(temp != nullptr)
return temp;
// if it's not what we're looking for, then check the expansion port on this expansion device. if it exists.
temp = dynamic_cast<device_t*>(exp_port->get_card_device());
- if(temp == NULL)
- return NULL; // no device attached
+ if(temp == nullptr)
+ return nullptr; // no device attached
exp_port = temp->subdevice<cpc_expansion_slot_device>("exp");
- if(exp_port == NULL)
- return NULL; // we're at the end of the chain
+ if(exp_port == nullptr)
+ return nullptr; // we're at the end of the chain
}
- return NULL;
+ return nullptr;
}
WRITE_LINE_MEMBER(amstrad_state::cpc_romdis)
@@ -1184,7 +1184,7 @@ void amstrad_state::amstrad_setLowerRom()
space.install_write_bank(0x6000, 0x7fff, "bank12");
}
*/
- if(m_AmstradCPC_RamBanks[0] != NULL)
+ if(m_AmstradCPC_RamBanks[0] != nullptr)
{
m_bank1->set_base(m_AmstradCPC_RamBanks[0]);
m_bank2->set_base(m_AmstradCPC_RamBanks[0]+0x2000);
@@ -1241,7 +1241,7 @@ void amstrad_state::amstrad_setLowerRom()
-----------------*/
void amstrad_state::amstrad_setUpperRom()
{
- UINT8 *bank_base = NULL;
+ UINT8 *bank_base = nullptr;
/* b3 : "1" Upper rom area disable or "0" Upper rom area enable */
if ( ! ( m_gate_array.mrer & 0x08 ) && m_gate_array.romdis == 0)
@@ -2000,14 +2000,14 @@ WRITE8_MEMBER(amstrad_state::rom_select)
// expansion devices know the selected ROM by monitoring I/O writes to DFxx
// there are no signals related to which ROM is selected
cpc_expansion_slot_device* exp_port = m_exp;
- while(exp_port != NULL)
+ while(exp_port != nullptr)
{
device_cpc_expansion_card_interface* temp;
device_t* temp_dev;
temp = dynamic_cast<device_cpc_expansion_card_interface*>(exp_port->get_card_device());
temp_dev = dynamic_cast<device_t*>(exp_port->get_card_device());
- if(temp != NULL)
+ if(temp != nullptr)
{
temp->set_rom_bank(data);
}
@@ -2192,7 +2192,7 @@ The exception is the case where none of b7-b0 are reset (i.e. port &FBFF), which
}
mface2 = dynamic_cast<cpc_multiface2_device*>(get_expansion_device(machine(),"multiface2"));
- if(mface2 != NULL)
+ if(mface2 != nullptr)
{
if(mface2->multiface_io_write(offset, data) != 0)
{
@@ -2429,7 +2429,7 @@ void amstrad_state::amstrad_rethinkMemory()
/* multiface hardware enabled? */
mface2 = dynamic_cast<cpc_multiface2_device*>(get_expansion_device(machine(),"multiface2"));
- if(mface2 != NULL)
+ if(mface2 != nullptr)
{
if (mface2->multiface_hardware_enabled())
{
@@ -2463,7 +2463,7 @@ void amstrad_state::screen_eof_amstrad(screen_device &screen, bool state)
{
cpc_multiface2_device* mface2 = dynamic_cast<cpc_multiface2_device*>(get_expansion_device(machine(),"multiface2"));
- if(mface2 != NULL)
+ if(mface2 != nullptr)
{
mface2->check_button_state();
}
@@ -2948,14 +2948,14 @@ void amstrad_state::enumerate_roms()
/* find any expansion devices that have a 'exp_rom' region */
cpc_expansion_slot_device* exp_port = m_exp;
- while(exp_port != NULL)
+ while(exp_port != nullptr)
{
device_t* temp;
temp = dynamic_cast<device_t*>(exp_port->get_card_device());
- if(temp != NULL)
+ if(temp != nullptr)
{
- if(temp->memregion("exp_rom")->base() != NULL)
+ if(temp->memregion("exp_rom")->base() != nullptr)
{
int num = temp->memregion("exp_rom")->bytes() / 0x4000;
for(i=0;i<num;i++)
@@ -2977,7 +2977,7 @@ void amstrad_state::enumerate_roms()
{
sprintf(str,"rom%i",i+1);
romimage = romexp->subdevice<rom_image_device>(str);
- if(romimage->base() != NULL)
+ if(romimage->base() != nullptr)
{
m_Amstrad_ROM_Table[m_rom_count] = romimage->base();
NEXT_ROM_SLOT
@@ -3089,7 +3089,7 @@ MACHINE_RESET_MEMBER(amstrad_state,amstrad)
// amstrad_init_palette(machine());
m_gate_array.de = 0;
- m_gate_array.draw_p = NULL;
+ m_gate_array.draw_p = nullptr;
m_gate_array.hsync = 0;
m_gate_array.vsync = 0;
@@ -3190,7 +3190,7 @@ MACHINE_START_MEMBER(amstrad_state,kccomp)
m_centronics->write_data7(0);
m_gate_array.de = 0;
- m_gate_array.draw_p = NULL;
+ m_gate_array.draw_p = nullptr;
m_gate_array.hsync = 0;
m_gate_array.vsync = 0;
@@ -3260,7 +3260,7 @@ DEVICE_IMAGE_LOAD_MEMBER(amstrad_state, amstrad_plus_cartridge)
logerror("IMG: loading CPC+ cartridge file\n");
// check for .CPR header
- if (image.software_entry() == NULL)
+ if (image.software_entry() == nullptr)
{
image.fread(header, 12);
if (strncmp((char *)header, "RIFF", 4) != 0)
@@ -3279,7 +3279,7 @@ DEVICE_IMAGE_LOAD_MEMBER(amstrad_state, amstrad_plus_cartridge)
m_cart->rom_alloc(size, GENERIC_ROM8_WIDTH, ENDIANNESS_LITTLE);
// actually load the cart into ROM
- if (image.software_entry() != NULL)
+ if (image.software_entry() != nullptr)
{
logerror("IMG: raw CPC+ cartridge from softlist\n");
memcpy(m_cart->get_rom_base(), image.get_software_region("rom"), size);
diff --git a/src/mame/machine/apollo.cpp b/src/mame/machine/apollo.cpp
index ecda2bdc9da..e10522756dd 100644
--- a/src/mame/machine/apollo.cpp
+++ b/src/mame/machine/apollo.cpp
@@ -1161,10 +1161,10 @@ MACHINE_CONFIG_FRAGMENT( common )
MCFG_ISA16_SLOT_ADD(APOLLO_ISA_TAG, "isa1", apollo_isa_cards, "wdc", false)
MCFG_ISA16_SLOT_ADD(APOLLO_ISA_TAG, "isa2", apollo_isa_cards, "ctape", false)
MCFG_ISA16_SLOT_ADD(APOLLO_ISA_TAG, "isa3", apollo_isa_cards, "3c505", false)
- MCFG_ISA16_SLOT_ADD(APOLLO_ISA_TAG, "isa4", apollo_isa_cards, NULL, false)
- MCFG_ISA16_SLOT_ADD(APOLLO_ISA_TAG, "isa5", apollo_isa_cards, NULL, false)
- MCFG_ISA16_SLOT_ADD(APOLLO_ISA_TAG, "isa6", apollo_isa_cards, NULL, false)
- MCFG_ISA16_SLOT_ADD(APOLLO_ISA_TAG, "isa7", apollo_isa_cards, NULL, false)
+ MCFG_ISA16_SLOT_ADD(APOLLO_ISA_TAG, "isa4", apollo_isa_cards, nullptr, false)
+ MCFG_ISA16_SLOT_ADD(APOLLO_ISA_TAG, "isa5", apollo_isa_cards, nullptr, false)
+ MCFG_ISA16_SLOT_ADD(APOLLO_ISA_TAG, "isa6", apollo_isa_cards, nullptr, false)
+ MCFG_ISA16_SLOT_ADD(APOLLO_ISA_TAG, "isa7", apollo_isa_cards, nullptr, false)
MCFG_SOFTWARE_LIST_ADD("ctape_list", "apollo_ctape")
MACHINE_CONFIG_END
diff --git a/src/mame/machine/apollo_dbg.cpp b/src/mame/machine/apollo_dbg.cpp
index be6b3811be7..f2991f8934c 100644
--- a/src/mame/machine/apollo_dbg.cpp
+++ b/src/mame/machine/apollo_dbg.cpp
@@ -18,37 +18,37 @@
//------------------------------------------------------
static const char* trap0[] = {
-/* 0x00 */NULL, NULL,
+/* 0x00 */nullptr, nullptr,
/* 0x01 */"FIM_$GET_FIM_ADDR", "",
-/* 0x02 */NULL, NULL,
+/* 0x02 */nullptr, nullptr,
/* 0x03 */"DTTY_$RELOAD_FONT", "",
/* 0x04 */"FILE_$UNLOCK_ALL", "",
-/* 0x05 */NULL, NULL,
-/* 0x06 */NULL, NULL,
+/* 0x05 */nullptr, nullptr,
+/* 0x06 */nullptr, nullptr,
/* 0x07 */"PROC2_$MY_PID", "",
/* 0x08 */"SMD_$OP_WAIT_U", "",
/* 0x09 */"TPAD_$RE_RANGE", "",
-/* 0x0a */NULL, NULL,
-/* 0x0b */NULL, NULL,
-/* 0x0c */NULL, NULL,
+/* 0x0a */nullptr, nullptr,
+/* 0x0b */nullptr, nullptr,
+/* 0x0c */nullptr, nullptr,
/* 0x0d */"ACL_$UP", "",
/* 0x0e */"ACL_$DOWN", "",
-/* 0x0f */NULL, NULL,
+/* 0x0f */nullptr, nullptr,
/* 0x10 */"TPAD_$INQ_DTYPE", "",
-/* 0x11 */NULL, NULL,
+/* 0x11 */nullptr, nullptr,
/* 0x12 */"CACHE_$CLEAR", "",
/* 0x13 */"RIP_$ANNOUNCE_NS", "",
-/* 0x14 */NULL, NULL,
-/* 0x15 */NULL, NULL,
-/* 0x16 */NULL, NULL,
-/* 0x17 */NULL, NULL,
+/* 0x14 */nullptr, nullptr,
+/* 0x15 */nullptr, nullptr,
+/* 0x16 */nullptr, nullptr,
+/* 0x17 */nullptr, nullptr,
/* 0x18 */"PROC2_$DELIVER_PENDING", "",
/* 0x19 */"PROC2_$COMPLETE_FORK", "",
/* 0x1a */"PACCT_$STOP", "",
/* 0x1b */"PACCT_$ON", "",
/* 0x1c */"ACL_$GET_LOCAL_LOCKSMITH", "",
/* 0x1d */"ACL_$IS_SUSER", "",
-/* 0x1e */NULL, NULL,
+/* 0x1e */nullptr, nullptr,
/* 0x1f */"SMD_$N_DEVICES", "",
/* 0x20 */"PROC1_$GET_MAXID", "",
/* 0x21 */"THREAD_$DELETE", "",
@@ -63,8 +63,8 @@ static const char* trap0[] = {
//------------------------------------------------------
static const char* trap1[] = {
-/* 0x00 */NULL, NULL,
-/* 0x01 */NULL, NULL,
+/* 0x00 */nullptr, nullptr,
+/* 0x01 */nullptr, nullptr,
/* 0x02 */"FIM_$INSTALL", "x",
/* 0x03 */"NETWORK_$READ_SERVICE", "x",
/* 0x04 */"PROC1_$GET_CPUT", "x",
@@ -77,26 +77,26 @@ static const char* trap1[] = {
/* 0x0b */"CAL_$REMOVE_LOCAL_OFFSET", "x",
/* 0x0c */"CAL_$SET_DRIFT", "x",
/* 0x0d */"DISK_$GET_ERROR_INFO", "x",
-/* 0x0e */NULL, NULL,
+/* 0x0e */nullptr, nullptr,
/* 0x0f */"MSG_$CLOSE", "x",
/* 0x10 */"PROC2_$WHO_AM_I", "u",
/* 0x11 */"SMD_$CLEAR_KBD_CURSOR", "x",
-/* 0x12 */NULL, NULL,
-/* 0x13 */NULL, NULL,
+/* 0x12 */nullptr, nullptr,
+/* 0x13 */nullptr, nullptr,
/* 0x14 */"SMD_$SEND_RESPONSE", "x",
/* 0x15 */"SMD_$STOP_TP_CURSOR", "x",
-/* 0x16 */NULL, NULL,
-/* 0x17 */NULL, NULL,
+/* 0x16 */nullptr, nullptr,
+/* 0x17 */nullptr, nullptr,
/* 0x18 */"SMD_$UNMAP_DISPLAY_U", "x",
/* 0x19 */"UID_$GEN", "x",
/* 0x1a */"TONE_$TIME", "x",
/* 0x1b */"SMD_$INQ_DISP_TYPE", "x",
-/* 0x1c */NULL, NULL,
-/* 0x1d */NULL, NULL,
-/* 0x1e */NULL, NULL,
+/* 0x1c */nullptr, nullptr,
+/* 0x1d */nullptr, nullptr,
+/* 0x1e */nullptr, nullptr,
/* 0x1f */"TPAD_$SET_CURSOR", "x",
-/* 0x20 */NULL, NULL,
-/* 0x21 */NULL, NULL,
+/* 0x20 */nullptr, nullptr,
+/* 0x21 */nullptr, nullptr,
/* 0x22 */"NAME_$GET_WDIR_UID", "u",
/* 0x23 */"NAME_$GET_NDIR_UID", "u",
/* 0x24 */"NAME_$GET_ROOT_UID", "u",
@@ -105,14 +105,14 @@ static const char* trap1[] = {
/* 0x27 */"NAME_$GET_CANNED_ROOT_UID", "u",
/* 0x28 */"MSG_$GET_MY_NET", "x",
/* 0x29 */"MSG_$GET_MY_NODE", "x",
-/* 0x2a */NULL, NULL,
-/* 0x2b */NULL, NULL,
-/* 0x2c */NULL, NULL,
-/* 0x2d */NULL, NULL,
-/* 0x2e */NULL, NULL,
-/* 0x2f */NULL, NULL,
+/* 0x2a */nullptr, nullptr,
+/* 0x2b */nullptr, nullptr,
+/* 0x2c */nullptr, nullptr,
+/* 0x2d */nullptr, nullptr,
+/* 0x2e */nullptr, nullptr,
+/* 0x2f */nullptr, nullptr,
/* 0x30 */"GPU_$INIT", "x",
-/* 0x31 */NULL, NULL,
+/* 0x31 */nullptr, nullptr,
/* 0x32 */"SMD_$INIT_STATE", "x",
/* 0x33 */"SMD_$CLR_TRK_RECT", "x",
/* 0x34 */"PROC2_$GET_SIG_MASK", "x",
@@ -120,14 +120,14 @@ static const char* trap1[] = {
/* 0x36 */"TIME_$GET_TIME_OF_DAY", "x",
/* 0x37 */"PROC1_$GET_LOADAV", "x",
/* 0x38 */"PROC2_$GET_BOOT_FLAGS", "x",
-/* 0x39 */NULL, NULL,
+/* 0x39 */nullptr, nullptr,
/* 0x3a */"PROC2_$SET_TTY", "x",
/* 0x3b */"OS_$SHUTDOWN", "x",
/* 0x3c */"PBU_$FAULTED_UNITS", "x",
/* 0x3d */"PROC2_$GET_CPU_USAGE", "x",
-/* 0x3e */NULL, NULL,
-/* 0x3f */NULL, NULL,
-/* 0x40 */NULL, NULL,
+/* 0x3e */nullptr, nullptr,
+/* 0x3f */nullptr, nullptr,
+/* 0x40 */nullptr, nullptr,
/* 0x41 */"TIME_$GET_ADJUST", "x",
/* 0x42 */"FILE_$SYNC", "x",
/* 0x43 */"XPAGE_$IS_MAPPED", "x",
@@ -139,11 +139,11 @@ static const char* trap1[] = {
//------------------------------------------------------
static const char* trap2[] = {
-/* 0x00 */NULL, NULL,
-/* 0x01 */NULL, NULL,
+/* 0x00 */nullptr, nullptr,
+/* 0x01 */nullptr, nullptr,
/* 0x02 */"FILE_$DELETE", "x,x",
/* 0x03 */"EC2_$WAKEUP", "x,x",
-/* 0x04 */NULL, NULL,
+/* 0x04 */nullptr, nullptr,
/* 0x05 */"ACL_$GET_SID", "x,x",
/* 0x06 */"FILE_$MK_PERMANENT", "x,x",
/* 0x07 */"FILE_$UNLOCK_VOL", "x,x",
@@ -156,13 +156,13 @@ static const char* trap2[] = {
/* 0x0e */"FILE_$MK_IMMUTABLE", "x,x",
/* 0x0f */"FILE_$PURIFY", "x,x",
/* 0x10 */"GET_BUILD_TIME", "x,x",
-/* 0x11 */NULL, NULL,
-/* 0x12 */NULL, NULL,
+/* 0x11 */nullptr, nullptr,
+/* 0x12 */nullptr, nullptr,
/* 0x13 */"MSG_$ALLOCATE", "x,x",
/* 0x14 */"MSG_$OPEN", "x,x",
/* 0x15 */"MSG_$WAIT", "x,x",
-/* 0x16 */NULL, NULL,
-/* 0x17 */NULL, NULL,
+/* 0x16 */nullptr, nullptr,
+/* 0x17 */nullptr, nullptr,
/* 0x18 */"PBU_$DEVICE_INTERRUPTING", "x,x",
/* 0x19 */"PBU_$DISABLE_DEVICE", "x,x",
/* 0x1a */"PBU_$ENABLE_DEVICE", "x,x",
@@ -170,23 +170,23 @@ static const char* trap2[] = {
/* 0x1c */"PROC2_$QUIT", "x,x",
/* 0x1d */"PROC2_$RESUME", "x,x",
/* 0x1e */"PROC2_$SUSPEND", "x,x",
-/* 0x1f */NULL, NULL,
-/* 0x20 */NULL, NULL,
-/* 0x21 */NULL, NULL,
-/* 0x22 */NULL, NULL,
-/* 0x23 */NULL, NULL,
-/* 0x24 */NULL, NULL,
-/* 0x25 */NULL, NULL,
+/* 0x1f */nullptr, nullptr,
+/* 0x20 */nullptr, nullptr,
+/* 0x21 */nullptr, nullptr,
+/* 0x22 */nullptr, nullptr,
+/* 0x23 */nullptr, nullptr,
+/* 0x24 */nullptr, nullptr,
+/* 0x25 */nullptr, nullptr,
/* 0x26 */"SMD_$MAP_DISPLAY_U", "x,x",
/* 0x27 */"SMD_$MOVE_KBD_CURSOR", "x,x",
-/* 0x28 */NULL, NULL,
+/* 0x28 */nullptr, nullptr,
/* 0x29 */"SMD_$RETURN_DISPLAY", "x,x",
-/* 0x2a */NULL, NULL,
-/* 0x2b */NULL, NULL,
-/* 0x2c */NULL, NULL,
-/* 0x2d */NULL, NULL,
+/* 0x2a */nullptr, nullptr,
+/* 0x2b */nullptr, nullptr,
+/* 0x2c */nullptr, nullptr,
+/* 0x2d */nullptr, nullptr,
/* 0x2e */"PEB_$GET_INFO", "x,x",
-/* 0x2f */NULL, NULL,
+/* 0x2f */nullptr, nullptr,
/* 0x30 */"EC2_$GET_VAL", "x,x",
/* 0x31 */"AST_$ADD_ASTES", "x,x",
/* 0x32 */"PBU_$DISSOC", "x,x",
@@ -194,42 +194,42 @@ static const char* trap2[] = {
/* 0x34 */"FILE_$DELETE_FORCE", "x,x",
/* 0x35 */"FILE_$DELETE_WHEN_UNLOCKED", "x,x",
/* 0x36 */"FILE_$MK_TEMPORARY", "x,x",
-/* 0x37 */NULL, NULL,
-/* 0x38 */NULL, NULL,
-/* 0x39 */NULL, NULL,
-/* 0x3a */NULL, NULL,
+/* 0x37 */nullptr, nullptr,
+/* 0x38 */nullptr, nullptr,
+/* 0x39 */nullptr, nullptr,
+/* 0x3a */nullptr, nullptr,
/* 0x3b */"SMD_$INQ_KBD_CURSOR", "x,x",
/* 0x3c */"ACL_$ENTER_SUBS", "u,x",
-/* 0x3d */NULL, NULL,
-/* 0x3e */NULL, NULL,
-/* 0x3f */NULL, NULL,
-/* 0x40 */NULL, NULL,
-/* 0x41 */NULL, NULL,
+/* 0x3d */nullptr, nullptr,
+/* 0x3e */nullptr, nullptr,
+/* 0x3f */nullptr, nullptr,
+/* 0x40 */nullptr, nullptr,
+/* 0x41 */nullptr, nullptr,
/* 0x42 */"FILE_$DELETE_FORCE_WHEN_UNLOCKED", "x,x",
-/* 0x43 */NULL, NULL,
+/* 0x43 */nullptr, nullptr,
/* 0x44 */"CT_$ACQUIRE", "x,x",
/* 0x45 */"HINT_$ADD", "x,x",
/* 0x46 */"DIR_$FIX_DIR", "x,x",
/* 0x47 */"NAME_$SET_WDIRUS", "u,x",
/* 0x48 */"NAME_$SET_NDIRUS", "u,x",
-/* 0x49 */NULL, NULL,
-/* 0x4a */NULL, NULL,
+/* 0x49 */nullptr, nullptr,
+/* 0x4a */nullptr, nullptr,
/* 0x4b */"MSG_$CLOSEI", "x,x",
/* 0x4c */"NETWORK_$ADD_PAGE_SERVERS", "x,x",
/* 0x4d */"NETWORK_$ADD_REQUEST_SERVERS", "x,x",
/* 0x4e */"ACL_$ADD_PROJ", "x,x",
/* 0x4f */"ACL_$DELETE_PROJ", "x,x",
-/* 0x50 */NULL, NULL,
-/* 0x51 */NULL, NULL,
+/* 0x50 */nullptr, nullptr,
+/* 0x51 */nullptr, nullptr,
/* 0x52 */"SMD_$SET_TP_REPORTING", "x,x",
/* 0x53 */"SMD_$DISABLE_TRACKING", "x,x",
-/* 0x54 */NULL, NULL,
-/* 0x55 */NULL, NULL,
-/* 0x56 */NULL, NULL,
-/* 0x57 */NULL, NULL,
+/* 0x54 */nullptr, nullptr,
+/* 0x55 */nullptr, nullptr,
+/* 0x56 */nullptr, nullptr,
+/* 0x57 */nullptr, nullptr,
/* 0x58 */"HINT_$ADDI", "x,x",
-/* 0x59 */NULL, NULL,
-/* 0x5a */NULL, NULL,
+/* 0x59 */nullptr, nullptr,
+/* 0x5a */nullptr, nullptr,
/* 0x5b */"PBU_$ALLOCATE_EC", "x,x",
/* 0x5c */"SMD_$SET_DISP_UNIT", "x,x",
/* 0x5d */"SMD_$VIDEO_CTL", "x,x",
@@ -253,26 +253,26 @@ static const char* trap2[] = {
/* 0x6f */"CAL_$DECODE_TIME", "x,x",
/* 0x70 */"ACL_$INHERIT_SUBSYS", "x,x",
/* 0x71 */"ACL_$SET_LOCAL_LOCKSMITH", "x,x",
-/* 0x72 */NULL, NULL,
+/* 0x72 */nullptr, nullptr,
/* 0x73 */"SMD_$DISSOC", "x,x",
/* 0x74 */"SMD_$BUSY_WAIT", "x,x",
/* 0x75 */"TTY_$K_OLD_RESET", "x,x",
-/* 0x76 */NULL, NULL,
-/* 0x77 */NULL, NULL,
-/* 0x78 */NULL, NULL,
+/* 0x76 */nullptr, nullptr,
+/* 0x77 */nullptr, nullptr,
+/* 0x78 */nullptr, nullptr,
/* 0x79 */"SCSI_$ABORT_OPERATION", "x,x",
/* 0x7a */"SCSI_$RELEASE", "x,x",
/* 0x7b */"SCSI_$RESET_DEVICE", "x,x",
-/* 0x7c */NULL, NULL,
+/* 0x7c */nullptr, nullptr,
/* 0x7d */"TPAD_$RE_RANGE_UNIT", "x,x",
/* 0x7e */"DISK_$FORMAT_WHOLE", "x,x",
-/* 0x7f */NULL, NULL,
-/* 0x80 */NULL, NULL,
-/* 0x81 */NULL, NULL,
-/* 0x82 */NULL, NULL,
-/* 0x83 */NULL, NULL,
+/* 0x7f */nullptr, nullptr,
+/* 0x80 */nullptr, nullptr,
+/* 0x81 */nullptr, nullptr,
+/* 0x82 */nullptr, nullptr,
+/* 0x83 */nullptr, nullptr,
/* 0x84 */"SMD_$SEND_UNIT_RESPONSE", "x,x",
-/* 0x85 */NULL, NULL,
+/* 0x85 */nullptr, nullptr,
/* 0x86 */"MST_$FW_XTAL", "x,x",
/* 0x87 */"THREAD_$TERMINATE", "x,x",
/* 0x88 */"THREAD_$TERMINATE_ALL", "u,x",
@@ -292,7 +292,7 @@ static const char* trap2[] = {
static const char* trap3[] = {
/* 0x00 */"PBU2_$DMA_STOP", "x,x,x",
-/* 0x01 */NULL, NULL,
+/* 0x01 */nullptr, nullptr,
/* 0x02 */"FILE_$CREATE", "x,x,x",
/* 0x03 */"FILE_$UNLOCK", "u,x,x",
/* 0x04 */"FILE_$TRUNCATE", "u,x,x",
@@ -301,10 +301,10 @@ static const char* trap3[] = {
/* 0x07 */"FILE_$ATTRIBUTES", "x,x,x",
/* 0x08 */"FILE_$SET_LEN", "x,x,x",
/* 0x09 */"FILE_$SET_TYPE", "x,x,x",
-/* 0x0a */NULL, NULL,
-/* 0x0b */NULL, NULL,
-/* 0x0c */NULL, NULL,
-/* 0x0d */NULL, NULL,
+/* 0x0a */nullptr, nullptr,
+/* 0x0b */nullptr, nullptr,
+/* 0x0c */nullptr, nullptr,
+/* 0x0d */nullptr, nullptr,
/* 0x0e */"NETWORK_$SET_SERVICE", "x,x,x",
/* 0x0f */"ASKNODE_$WHO", "s,x,x",
/* 0x10 */"FILE_$ACT_ATTRIBUTES", "x,x,x",
@@ -314,11 +314,11 @@ static const char* trap3[] = {
/* 0x14 */"FILE_$SET_ACL", "x,x,x",
/* 0x15 */"FILE_$SET_DIRPTR", "x,x,x",
/* 0x16 */"FILE_$SET_TROUBLE", "x,x,x",
-/* 0x17 */NULL, NULL,
-/* 0x18 */NULL, NULL,
-/* 0x19 */NULL, NULL,
-/* 0x1a */NULL, NULL,
-/* 0x1b */NULL, NULL,
+/* 0x17 */nullptr, nullptr,
+/* 0x18 */nullptr, nullptr,
+/* 0x19 */nullptr, nullptr,
+/* 0x1a */nullptr, nullptr,
+/* 0x1b */nullptr, nullptr,
/* 0x1c */"PBU_$DMA_STOP", "x,x,x",
/* 0x1d */"PBU_$SETDOWN", "x,x,x",
/* 0x1e */"PBU_$SETUP", "x,x,x",
@@ -326,35 +326,35 @@ static const char* trap3[] = {
/* 0x20 */"FIM_$SINGLE_STEP", "x,x,x",
/* 0x21 */"SMD_$ASSOC", "x,x,x",
/* 0x22 */"SMD_$BORROW_DISPLAY", "x,x,x",
-/* 0x23 */NULL, NULL,
-/* 0x24 */NULL, NULL,
+/* 0x23 */nullptr, nullptr,
+/* 0x24 */nullptr, nullptr,
/* 0x25 */"SMD_$SET_TP_CURSOR", "x,x,x",
/* 0x26 */"TIME_$WAIT", "x,x,x",
/* 0x27 */"RINGLOG_$CNTL", "x,x,x",
/* 0x28 */"SMD_$ALLOC_HDM", "x,x,x",
/* 0x29 */"SMD_$FREE_HDM", "x,x,x",
-/* 0x2a */NULL, NULL,
+/* 0x2a */nullptr, nullptr,
/* 0x2b */"OS_$GET_EC", "x,x,x",
/* 0x2c */"TIME_$GET_EC", "x,x,x",
-/* 0x2d */NULL, NULL,
+/* 0x2d */nullptr, nullptr,
/* 0x2e */"PROC2_$UPID_TO_UID", "x,u,x",
/* 0x2f */"MSG_$GET_EC", "x,x,x",
/* 0x30 */"DISK_$AS_OPTIONS", "x,x,x",
/* 0x31 */"SMD_$GET_EC", "x,x,x",
/* 0x32 */"NAME_$SET_ACL", "x,x,x",
/* 0x33 */"FILE_$SET_REFCNT", "x,x,x",
-/* 0x34 */NULL, NULL,
+/* 0x34 */nullptr, nullptr,
/* 0x35 */"PROC1_$GET_INFO", "x,x,x",
-/* 0x36 */NULL, NULL,
-/* 0x37 */NULL, NULL,
-/* 0x38 */NULL, NULL,
-/* 0x39 */NULL, NULL,
-/* 0x3a */NULL, NULL,
-/* 0x3b */NULL, NULL,
+/* 0x36 */nullptr, nullptr,
+/* 0x37 */nullptr, nullptr,
+/* 0x38 */nullptr, nullptr,
+/* 0x39 */nullptr, nullptr,
+/* 0x3a */nullptr, nullptr,
+/* 0x3b */nullptr, nullptr,
/* 0x3c */"AS_$GET_INFO", "x,x,x",
/* 0x3d */"FILE_$SET_DTM", "x,x,x",
/* 0x3e */"FILE_$SET_DTU", "x,x,x",
-/* 0x3f */NULL, NULL,
+/* 0x3f */nullptr, nullptr,
/* 0x40 */"LOG_$READ", "x,x,x",
/* 0x41 */"PROC2_$SET_PGROUP", "x,x,x",
/* 0x42 */"SMD_$SET_BLANK_TIMEOUT", "x,x,x",
@@ -364,12 +364,12 @@ static const char* trap3[] = {
/* 0x46 */"PROC2_$UPGID_TO_UID", "x,x,x",
/* 0x47 */"TIME_$GET_ITIMER", "x,x,x",
/* 0x48 */"DIR_$SET_DAD", "x,x,x",
-/* 0x49 */NULL, NULL,
-/* 0x4a */NULL, NULL,
-/* 0x4b */NULL, NULL,
-/* 0x4c */NULL, NULL,
-/* 0x4d */NULL, NULL,
-/* 0x4e */NULL, NULL,
+/* 0x49 */nullptr, nullptr,
+/* 0x4a */nullptr, nullptr,
+/* 0x4b */nullptr, nullptr,
+/* 0x4c */nullptr, nullptr,
+/* 0x4d */nullptr, nullptr,
+/* 0x4e */nullptr, nullptr,
/* 0x4f */"RIP_$TABLE", "x,x,x",
/* 0x50 */"FILE_$LOCATEI", "x,x,x",
/* 0x51 */"MSG_$OPENI", "x,x,x",
@@ -377,25 +377,25 @@ static const char* trap3[] = {
/* 0x53 */"MSG_$WAITI", "x,x,x",
/* 0x54 */"ACL_$SET_PROJ_LIST", "x,x,x",
/* 0x55 */"ACL_$GET_RE_SIDS", "x,x,x",
-/* 0x56 */NULL, NULL,
+/* 0x56 */nullptr, nullptr,
/* 0x57 */"MSG_$SET_HPIPC", "x,x,x",
/* 0x58 */"DIR_$VALIDATE_ROOT_ENTRY", "x,x,x",
/* 0x59 */"SMD_$ENABLE_TRACKING", "x,x,x",
/* 0x5a */"FILE_$READ_LOCK_ENTRYUI", "x,x,x",
-/* 0x5b */NULL, NULL,
+/* 0x5b */nullptr, nullptr,
/* 0x5c */"ROUTE_$SERVICE", "x,x,x",
-/* 0x5d */NULL, NULL,
-/* 0x5e */NULL, NULL,
-/* 0x5f */NULL, NULL,
+/* 0x5d */nullptr, nullptr,
+/* 0x5e */nullptr, nullptr,
+/* 0x5f */nullptr, nullptr,
/* 0x60 */"PBU_$ADVANCE_EC", "x,x,x",
/* 0x61 */"PBU_$RELEASE_EC", "x,x,x",
-/* 0x62 */NULL, NULL,
+/* 0x62 */nullptr, nullptr,
/* 0x63 */"SMD_$GET_IDM_EVENT", "x,x,x",
/* 0x64 */"MSG_$TEST_FOR_MESSAGE", "x,x,x",
/* 0x65 */"SMD_$ADD_TRK_RECT", "x,x,x",
/* 0x66 */"SMD_$DEL_TRK_RECT", "x,x,x",
/* 0x67 */"SMD_$SET_KBD_TYPE", "x,x,x",
-/* 0x68 */NULL, NULL,
+/* 0x68 */nullptr, nullptr,
/* 0x69 */"FILE_$SET_AUDITED", "x,x,x",
/* 0x6a */"PROC2_$ACKNOWLEDGE", "x,x,x",
/* 0x6b */"PROC2_$GET_MY_UPIDS", "x,x,x",
@@ -423,7 +423,7 @@ static const char* trap3[] = {
/* 0x81 */"PROC2_$PGUID_TO_UPGID", "x,x,x",
/* 0x82 */"TERM_$INQ_DISCIPLINE", "x,x,x",
/* 0x83 */"PBU_$DMA_STATUS", "x,x,x",
-/* 0x84 */NULL, NULL,
+/* 0x84 */nullptr, nullptr,
/* 0x85 */"MST_$UNMAPS_AND_FREE_AREA", "x,x,x",
/* 0x86 */"SMD_$ASSOC_CSRS", "x,x,x",
/* 0x87 */"SMD_$INQ_DISP_INFO", "x,x,x",
@@ -439,17 +439,17 @@ static const char* trap3[] = {
/* 0x91 */"TPAD_$INQ_PUNCH_IMPACT", "x,x,x",
/* 0x92 */"TTY_$K_INQ_SESSION_ID", "x,x,x",
/* 0x93 */"TTY_$K_SET_SESSION_ID", "x,x,x",
-/* 0x94 */NULL, NULL,
-/* 0x95 */NULL, NULL,
-/* 0x96 */NULL, NULL,
-/* 0x97 */NULL, NULL,
+/* 0x94 */nullptr, nullptr,
+/* 0x95 */nullptr, nullptr,
+/* 0x96 */nullptr, nullptr,
+/* 0x97 */nullptr, nullptr,
/* 0x98 */"SMD_$SHARE_DEVICE", "x,x,x",
/* 0x99 */"SMD_$SET_UNIT_CURSOR_POS", "x,x,x",
/* 0x9a */"SMD_$CLR_AND_LOAD_TRK_RECT", "x,x,x",
/* 0x9b */"PROC2_$GET_PARM", "x,x,x",
-/* 0x9c */NULL, NULL,
-/* 0x9d */NULL, NULL,
-/* 0x9e */NULL, NULL,
+/* 0x9c */nullptr, nullptr,
+/* 0x9d */nullptr, nullptr,
+/* 0x9e */nullptr, nullptr,
/* 0x9f */"FILE_$CW_READ", "x,x,x",
/* 0xa0 */"FILE_$CW_WRITE", "x,x,x",
/* 0xa1 */"MST_$TRUNC_XTAL", "x,x,x",
@@ -461,17 +461,17 @@ static const char* trap3[] = {
/* 0xa7 */"THREAD_$CLEANUP_ALL", "x,x,x",
/* 0xa8 */"DIR_$ADD_MOUNT", "x,x,x",
/* 0xa9 */"DIR_$REMOVE_MOUNT", "x,x,x",
-/* 0xaa */NULL, NULL,
+/* 0xaa */nullptr, nullptr,
/* 0xab */"TTY_$K_RESET", "x,x,x",
/* 0xac */"MST_$SHADOW_MAP", "x,x,x",
-/* 0xad */NULL, NULL };
+/* 0xad */nullptr, nullptr };
//------------------------------------------------------
// TRAP4
//------------------------------------------------------
static const char* trap4[] = {
-/* 0x00 */NULL, NULL,
+/* 0x00 */nullptr, nullptr,
/* 0x01 */"MST_$SET_GUARD", "u,x,x,x",
/* 0x02 */"MST_$UNMAP_GLOBAL", "u,x,x,x",
/* 0x03 */"MST_$GET_UID", "x,u,x,x",
@@ -479,81 +479,81 @@ static const char* trap4[] = {
/* 0x05 */"FILE_$READ_LOCK_ENTRY", "x,x,x,x",
/* 0x06 */"MST_$UNMAP", "u,x,x,x",
/* 0x07 */"MST_$GROW_AREA", "x,x,x,x",
-/* 0x08 */NULL, NULL,
-/* 0x09 */NULL, NULL,
-/* 0x0a */NULL, NULL,
-/* 0x0b */NULL, NULL,
+/* 0x08 */nullptr, nullptr,
+/* 0x09 */nullptr, nullptr,
+/* 0x0a */nullptr, nullptr,
+/* 0x0b */nullptr, nullptr,
/* 0x0c */"TERM_$CONTROL", "x,x,x,x",
/* 0x0d */"TERM_$READ", "x,s,x,x",
/* 0x0e */"TERM_$WRITE", "x,x,x,x",
/* 0x0f */"DISK_$FORMAT", "x,x,x,x",
/* 0x10 */"DISK_$LV_ASSIGN", "x,x,x,x",
/* 0x11 */"FILE_$FW_PARTIAL", "x,x,x,x",
-/* 0x12 */NULL, NULL,
-/* 0x13 */NULL, NULL,
-/* 0x14 */NULL, NULL,
-/* 0x15 */NULL, NULL,
-/* 0x16 */NULL, NULL,
-/* 0x17 */NULL, NULL,
-/* 0x18 */NULL, NULL,
-/* 0x19 */NULL, NULL,
-/* 0x1a */NULL, NULL,
-/* 0x1b */NULL, NULL,
-/* 0x1c */NULL, NULL,
-/* 0x1d */NULL, NULL,
-/* 0x1e */NULL, NULL,
-/* 0x1f */NULL, NULL,
-/* 0x20 */NULL, NULL,
-/* 0x21 */NULL, NULL,
-/* 0x22 */NULL, NULL,
+/* 0x12 */nullptr, nullptr,
+/* 0x13 */nullptr, nullptr,
+/* 0x14 */nullptr, nullptr,
+/* 0x15 */nullptr, nullptr,
+/* 0x16 */nullptr, nullptr,
+/* 0x17 */nullptr, nullptr,
+/* 0x18 */nullptr, nullptr,
+/* 0x19 */nullptr, nullptr,
+/* 0x1a */nullptr, nullptr,
+/* 0x1b */nullptr, nullptr,
+/* 0x1c */nullptr, nullptr,
+/* 0x1d */nullptr, nullptr,
+/* 0x1e */nullptr, nullptr,
+/* 0x1f */nullptr, nullptr,
+/* 0x20 */nullptr, nullptr,
+/* 0x21 */nullptr, nullptr,
+/* 0x22 */nullptr, nullptr,
/* 0x23 */"PBU_$WAIT", "x,x,x,x",
/* 0x24 */"PBU_$GET_PTR", "x,x,x,x",
/* 0x25 */"PCHIST_$CNTL", "x,x,x,x",
/* 0x26 */"PROC2_$GET_INFO", "u,x,x,x",
-/* 0x27 */NULL, NULL,
-/* 0x28 */NULL, NULL,
-/* 0x29 */NULL, NULL,
+/* 0x27 */nullptr, nullptr,
+/* 0x28 */nullptr, nullptr,
+/* 0x29 */nullptr, nullptr,
/* 0x2a */"SMD_$SIGNAL", "x,x,x,x",
-/* 0x2b */NULL, NULL,
-/* 0x2c */NULL, NULL,
+/* 0x2b */nullptr, nullptr,
+/* 0x2c */nullptr, nullptr,
/* 0x2d */"TERM_$INQUIRE", "x,x,x,x",
-/* 0x2e */NULL, NULL,
-/* 0x2f */NULL, NULL,
-/* 0x30 */NULL, NULL,
+/* 0x2e */nullptr, nullptr,
+/* 0x2f */nullptr, nullptr,
+/* 0x30 */nullptr, nullptr,
/* 0x31 */"TERM_$GET_EC", "x,x,x,x",
-/* 0x32 */NULL, NULL,
+/* 0x32 */nullptr, nullptr,
/* 0x33 */"PBU_$GET_EC", "x,x,x,x",
-/* 0x34 */NULL, NULL,
-/* 0x35 */NULL, NULL,
-/* 0x36 */NULL, NULL,
-/* 0x37 */NULL, NULL,
+/* 0x34 */nullptr, nullptr,
+/* 0x35 */nullptr, nullptr,
+/* 0x36 */nullptr, nullptr,
+/* 0x37 */nullptr, nullptr,
/* 0x38 */"TERM_$READ_COND", "x,x,x,x",
-/* 0x39 */NULL, NULL,
-/* 0x3a */NULL, NULL,
+/* 0x39 */nullptr, nullptr,
+/* 0x3a */nullptr, nullptr,
/* 0x3b */"PBU2_$WIRE", "x,x,x,x",
/* 0x3c */"PROC2_$SET_NAME", "x,x,x,x",
/* 0x3d */"PROC2_$SET_PRIORITY", "x,x,x,x",
/* 0x3e */"PROC2_$GET_EC", "u,x,x,x",
/* 0x3f */"PROC2_$LIST_PGROUP", "x,x,x,x",
-/* 0x40 */NULL, NULL,
-/* 0x41 */NULL, NULL,
-/* 0x42 */NULL, NULL,
+/* 0x40 */nullptr, nullptr,
+/* 0x41 */nullptr, nullptr,
+/* 0x42 */nullptr, nullptr,
/* 0x43 */"CT_$CONTROL", "x,x,x,x",
/* 0x44 */"CT_$WAIT", "x,x,x,x",
/* 0x45 */"DIR_$DROP_DIRU", "x,x,x,x",
/* 0x46 */"DIR_$SET_DEFAULT_ACL", "x,x,x,x",
/* 0x47 */"DIR_$GET_DEFAULT_ACL", "x,x,x,x",
/* 0x48 */"NAME_$READ_DIRS_PS", "x,x,x,x",
-/* 0x49 */NULL, NULL,
+/* 0x49 */nullptr, nullptr,
/* 0x4a */"ACL_$GET_PROJ_LIST", "x,x,x,x",
/* 0x4b */"MST_$CHANGE_RIGHTS", "x,x,x,x",
-/* 0x4c */NULL, NULL,
+/* 0x4c */nullptr, nullptr,
/* 0x4d */"FILE_$READ_LOCK_ENTRYI", "x,x,x,x",
/* 0x4e */"ROUTE_$INCOMING", "x,x,x,x",
-/* 0x4f */NULL, NULL,
+/* 0x4f */nullptr, nullptr,
/* 0x50 */"SMD_$INQ_KBD_TYPE", "x,x,x,x",
/* 0x51 */"ROUTE_$GET_EC", "x,x,x,x",
-/* 0x52 */NULL, NULL,
+/* 0x52 */nullptr, nullptr,
/* 0x53 */"SMD_$DM_COND_EVENT_WAIT", "x,x,x,x",
/* 0x54 */"DISK_$READ_MFG_BADSPOTS", "x,x,x,x",
/* 0x55 */"DISK_$GET_MNT_INFO", "x,x,x,x",
@@ -575,7 +575,7 @@ static const char* trap4[] = {
/* 0x65 */"XPD_$GET_REGISTERS", "x,x,x,x",
/* 0x66 */"XPD_$PUT_REGISTERS", "x,x,x,x",
/* 0x67 */"FILE_$RESERVE", "u,x,x,x",
-/* 0x68 */NULL, NULL,
+/* 0x68 */nullptr, nullptr,
/* 0x69 */"ACL_$GET_RES_SIDS", "x,x,x,x",
/* 0x6a */"FILE_$FW_PAGES", "x,x,x,x",
/* 0x6b */"PROC2_$SET_ACCT_INFO", "s,x,x,x",
@@ -585,13 +585,13 @@ static const char* trap4[] = {
/* 0x6f */"FILE_$TRUNCATE_D", "x,x,x,x",
/* 0x70 */"FILE_$SET_DTM_F", "x,x,x,x",
/* 0x71 */"TTY_$K_SET_FLAG", "x,x,x,x",
-/* 0x72 */NULL, NULL,
+/* 0x72 */nullptr, nullptr,
/* 0x73 */"MST_$UNMAP_AND_FREE_AREA", "x,x,x,x",
-/* 0x74 */NULL, NULL,
+/* 0x74 */nullptr, nullptr,
/* 0x75 */"PROC2_$NAME_TO_UID", "S,w,u,x",
-/* 0x76 */NULL, NULL,
-/* 0x77 */NULL, NULL,
-/* 0x78 */NULL, NULL,
+/* 0x76 */nullptr, nullptr,
+/* 0x77 */nullptr, nullptr,
+/* 0x78 */nullptr, nullptr,
/* 0x79 */"SCSI_$GET_EC", "x,x,x,x",
/* 0x7a */"SCSI_$GET_INFO", "x,x,x,x",
/* 0x7b */"SCSI_$SETUP", "x,x,x,x",
@@ -599,12 +599,12 @@ static const char* trap4[] = {
/* 0x7d */"MSG_$SHARE_SOCKET", "x,x,x,x",
/* 0x7e */"TTY_$K_INQ_DELAY", "x,x,x,x",
/* 0x7f */"TTY_$K_SET_DELAY", "x,x,x,x",
-/* 0x80 */NULL, NULL,
-/* 0x81 */NULL, NULL,
+/* 0x80 */nullptr, nullptr,
+/* 0x81 */nullptr, nullptr,
/* 0x82 */"PROC2_$PGROUP_INFO", "x,x,x,x",
/* 0x83 */"PROC2_$SET_PARM", "x,x,x,x",
-/* 0x84 */NULL, NULL,
-/* 0x85 */NULL, NULL,
+/* 0x84 */nullptr, nullptr,
+/* 0x85 */nullptr, nullptr,
/* 0x86 */"XPAGE_$PAGER_RENDEZVOUS", "x,x,x,x",
/* 0x87 */"FILE_$SET_DEVNO32", "x,x,x,x",
/* 0x88 */"MST_$SET_LIMIT", "x,x,x,x",
@@ -618,23 +618,23 @@ static const char* trap4[] = {
//------------------------------------------------------
static const char* trap5[] = {
-/* 0x00 */NULL, NULL,
+/* 0x00 */nullptr, nullptr,
/* 0x01 */"MST_$MAP_AREA", "x,x,x,u,x",
-/* 0x02 */NULL, NULL,
-/* 0x03 */NULL, NULL,
-/* 0x04 */NULL, NULL,
+/* 0x02 */nullptr, nullptr,
+/* 0x03 */nullptr, nullptr,
+/* 0x04 */nullptr, nullptr,
/* 0x05 */"ACL_$RIGHTS", "x,x,x,x,x",
-/* 0x06 */NULL, NULL,
+/* 0x06 */nullptr, nullptr,
/* 0x07 */"ASKNODE_$INFO", "x,x,x,x,x",
/* 0x08 */"DISK_$AS_READ", "x,x,x,x,x",
/* 0x09 */"DISK_$AS_WRITE", "x,x,x,x,x",
-/* 0x0a */NULL, NULL,
-/* 0x0b */NULL, NULL,
-/* 0x0c */NULL, NULL,
-/* 0x0d */NULL, NULL,
-/* 0x0e */NULL, NULL,
-/* 0x0f */NULL, NULL,
-/* 0x10 */NULL, NULL,
+/* 0x0a */nullptr, nullptr,
+/* 0x0b */nullptr, nullptr,
+/* 0x0c */nullptr, nullptr,
+/* 0x0d */nullptr, nullptr,
+/* 0x0e */nullptr, nullptr,
+/* 0x0f */nullptr, nullptr,
+/* 0x10 */nullptr, nullptr,
/* 0x11 */"PBU_$GET_DCTE", "x,x,x,x,x",
/* 0x12 */"PBU_$READ_CSR", "x,x,x,x,x",
/* 0x13 */"PBU_$CONTROL", "x,x,x,x,x",
@@ -647,8 +647,8 @@ static const char* trap5[] = {
/* 0x1a */"VTOC_$GET_UID", "x,x,x,x,x",
/* 0x1b */"NETLOG_$CNTL", "x,x,x,x,x",
/* 0x1c */"PROC2_$GET_UPIDS", "x,x,x,x,x",
-/* 0x1d */NULL, NULL,
-/* 0x1e */NULL, NULL,
+/* 0x1d */nullptr, nullptr,
+/* 0x1e */nullptr, nullptr,
/* 0x1f */"PBU2_$ALLOCATE_MAP", "x,x,x,x,x",
/* 0x20 */"PBU2_$MAP", "x,x,x,x,x",
/* 0x21 */"PBU2_$UNMAP", "x,x,x,x,x",
@@ -656,13 +656,13 @@ static const char* trap5[] = {
/* 0x23 */"MST_$GET_UID_ASID", "x,x,x,x,x",
/* 0x24 */"MST_$INVALIDATE", "x,x,u,x,x",
/* 0x25 */"FILE_$INVALIDATE", "x,x,x,x,x",
-/* 0x26 */NULL, NULL,
-/* 0x27 */NULL, NULL,
-/* 0x28 */NULL, NULL,
+/* 0x26 */nullptr, nullptr,
+/* 0x27 */nullptr, nullptr,
+/* 0x28 */nullptr, nullptr,
/* 0x29 */"MST_$SET_TOUCH_AHEAD_CNT", "x,x,x,x,x",
/* 0x2a */"OS_$CHKSUM", "x,x,x,x,x",
/* 0x2b */"FILE_$GET_SEGMENT_MAP", "x,x,x,x,x",
-/* 0x2c */NULL, NULL,
+/* 0x2c */nullptr, nullptr,
/* 0x2d */"PBU2_$ASSOC", "x,x,x,x,x",
/* 0x2e */"FILE_$UNLOCK_PROC", "x,x,x,x,x",
/* 0x2f */"CT_$READ", "x,x,x,x,x",
@@ -671,19 +671,19 @@ static const char* trap5[] = {
/* 0x32 */"DIR_$DROPU", "x,x,x,x,x",
/* 0x33 */"DIR_$CREATE_DIRU", "x,x,x,x,x",
/* 0x34 */"DIR_$ADD_BAKU", "x,x,x,x,x",
-/* 0x35 */NULL, NULL,
-/* 0x36 */NULL, NULL,
-/* 0x37 */NULL, NULL,
+/* 0x35 */nullptr, nullptr,
+/* 0x36 */nullptr, nullptr,
+/* 0x37 */nullptr, nullptr,
/* 0x38 */"DIR_$ADD_HARD_LINKU", "x,x,x,x,x",
-/* 0x39 */NULL, NULL,
+/* 0x39 */nullptr, nullptr,
/* 0x3a */"RIP_$UPDATE", "x,x,x,x,x",
/* 0x3b */"DIR_$DROP_LINKU", "x,x,x,x,x",
/* 0x3c */"ACL_$CHECK_RIGHTS", "x,x,x,x,x",
/* 0x3d */"DIR_$DROP_HARD_LINKU", "x,x,x,x,x",
/* 0x3e */"ROUTE_$OUTGOING", "x,x,x,x,x",
-/* 0x3f */NULL, NULL,
-/* 0x40 */NULL, NULL,
-/* 0x41 */NULL, NULL,
+/* 0x3f */nullptr, nullptr,
+/* 0x40 */nullptr, nullptr,
+/* 0x41 */nullptr, nullptr,
/* 0x42 */"NET_$GET_INFO", "x,x,x,x,x",
/* 0x43 */"DIR_$GET_ENTRYU", "x,x,x,x,x",
/* 0x44 */"AUDIT_$LOG_EVENT", "x,x,x,x,x",
@@ -691,7 +691,7 @@ static const char* trap5[] = {
/* 0x46 */"TTY_$K_GET", "x,x,s,x,x",
/* 0x47 */"TTY_$K_PUT", "x,x,S,w,x",
/* 0x48 */"PROC2_$ALIGN_CTL", "x,x,x,x,x",
-/* 0x49 */NULL, NULL,
+/* 0x49 */nullptr, nullptr,
/* 0x4a */"XPD_$READ_PROC", "x,x,x,x,x",
/* 0x4b */"XPD_$WRITE_PROC", "x,x,x,x,x",
/* 0x4c */"DIR_$SET_DEF_PROTECTION", "x,x,x,x,x",
@@ -705,24 +705,24 @@ static const char* trap5[] = {
/* 0x54 */"FILE_$EXPORT_LK", "x,x,x,x,x",
/* 0x55 */"FILE_$CHANGE_LOCK_D", "x,x,x,x,x",
/* 0x56 */"XPD_$READ_PROC_ASYNC", "x,x,x,x,x",
-/* 0x57 */NULL, NULL,
+/* 0x57 */nullptr, nullptr,
/* 0x58 */"SMD_$MAP_DISPLAY_MEMORY", "x,x,x,x,x",
-/* 0x59 */NULL, NULL,
-/* 0x5a */NULL, NULL,
-/* 0x5b */NULL, NULL,
-/* 0x5c */NULL, NULL,
+/* 0x59 */nullptr, nullptr,
+/* 0x5a */nullptr, nullptr,
+/* 0x5b */nullptr, nullptr,
+/* 0x5c */nullptr, nullptr,
/* 0x5d */"SCSI_$UNWIRE", "x,x,x,x,x",
/* 0x5e */"SMD_$UNMAP_DISPLAY_MEMORY", "x,x,x,x,x",
/* 0x5f */"SMD_$SET_COLOR_TABLE", "x,x,x,x,x",
/* 0x60 */"RIP_$TABLE_D", "x,x,x,x,x",
-/* 0x61 */NULL, NULL,
+/* 0x61 */nullptr, nullptr,
/* 0x62 */"SMD_$DEVICE_INFO", "x,x,x,x,x",
-/* 0x63 */NULL, NULL,
-/* 0x64 */NULL, NULL,
+/* 0x63 */nullptr, nullptr,
+/* 0x64 */nullptr, nullptr,
/* 0x65 */"THREAD_$GET_STATE", "x,x,x,p,x",
/* 0x66 */"THREAD_$SET_STATE", "x,x,x,p,x",
/* 0x67 */"THREAD_$SET_STACK", "x,u,x,x,x",
-/* 0x68 */NULL, NULL };
+/* 0x68 */nullptr, nullptr };
//------------------------------------------------------
// TRAP7
@@ -732,50 +732,50 @@ static const char* trap7[] = {
/* 0x00 */"FILE_$LOCK", "u,x,x,x,x,x,x",
/* 0x01 */"VFMT_$WRITE", "s,x,x,x,x,x,x",
/* 0x02 */"MST_$MAP_AREA_AT", "x,x,x,x,x,x,x",
-/* 0x03 */NULL, NULL,
-/* 0x04 */NULL, NULL,
-/* 0x05 */NULL, NULL,
-/* 0x06 */NULL, NULL,
-/* 0x07 */NULL, NULL,
-/* 0x08 */NULL, NULL,
-/* 0x09 */NULL, NULL,
-/* 0x0a */NULL, NULL,
-/* 0x0b */NULL, NULL,
-/* 0x0c */NULL, NULL,
+/* 0x03 */nullptr, nullptr,
+/* 0x04 */nullptr, nullptr,
+/* 0x05 */nullptr, nullptr,
+/* 0x06 */nullptr, nullptr,
+/* 0x07 */nullptr, nullptr,
+/* 0x08 */nullptr, nullptr,
+/* 0x09 */nullptr, nullptr,
+/* 0x0a */nullptr, nullptr,
+/* 0x0b */nullptr, nullptr,
+/* 0x0c */nullptr, nullptr,
/* 0x0d */"VFMT_$ENCODE/VFMT_$FORMAT", "x,x,x,x,x,x,x",
/* 0x0e */"VFMT_$ENCODE/VFMT_$FORMAT", "x,x,x,x,x,x,x",
/* 0x0f */"STOP_$WATCH", "x,x,x,x,x,x,x",
-/* 0x10 */NULL, NULL,
-/* 0x11 */NULL, NULL,
+/* 0x10 */nullptr, nullptr,
+/* 0x11 */nullptr, nullptr,
/* 0x12 */"ASKNODE_$GET_INFO", "x,x,x,x,x,x,x",
/* 0x13 */"DISK_$DIAG_IO", "x,x,x,x,x,x,x",
-/* 0x14 */NULL, NULL,
-/* 0x15 */NULL, NULL,
-/* 0x16 */NULL, NULL,
+/* 0x14 */nullptr, nullptr,
+/* 0x15 */nullptr, nullptr,
+/* 0x16 */nullptr, nullptr,
/* 0x17 */"CT_$DIAG", "x,x,x,x,x,x,x",
/* 0x18 */"TIME_$SET_ITIMER", "x,x,x,x,x,x,x",
/* 0x19 */"OSINFO_$GET_STATS", "x,x,x,x,x,x,x",
/* 0x1a */"DIR_$CNAMEU", "x,x,x,x,x,x,x",
/* 0x1b */"DIR_$DELETE_FILEU", "u,S,w,x,x,x,x",
/* 0x1c */"DIR_$ADD_LINKU", "x,x,x,x,x,x,x",
-/* 0x1d */NULL, NULL,
-/* 0x1e */NULL, NULL,
-/* 0x1f */NULL, NULL,
-/* 0x20 */NULL, NULL,
+/* 0x1d */nullptr, nullptr,
+/* 0x1e */nullptr, nullptr,
+/* 0x1f */nullptr, nullptr,
+/* 0x20 */nullptr, nullptr,
/* 0x21 */"ASKNODE_$WHO_REMOTE", "x,x,x,x,x,x,x",
/* 0x22 */"MST_$REMAP", "x,x,x,x,x,x,x",
/* 0x23 */"DIR_$ROOT_ADDU", "x,x,x,x,x,x,x",
-/* 0x24 */NULL, NULL,
-/* 0x25 */NULL, NULL,
-/* 0x26 */NULL, NULL,
-/* 0x27 */NULL, NULL,
+/* 0x24 */nullptr, nullptr,
+/* 0x25 */nullptr, nullptr,
+/* 0x26 */nullptr, nullptr,
+/* 0x27 */nullptr, nullptr,
/* 0x28 */"ASKNODE_$WHO_NOTOPO", "x,x,x,x,x,x,x",
/* 0x29 */"NET_$OPEN", "x,x,x,x,x,x,x",
/* 0x2a */"NET_$CLOSE", "x,x,x,x,x,x,x",
/* 0x2b */"NET_$IOCTL", "x,x,x,x,x,x,x",
/* 0x2c */"DIR_$FIND_UID", "u,u,x,S,w,x,x",
/* 0x2d */"FILE_$GET_ATTRIBUTES", "u,x,x,x,x,x,-",
-/* 0x2e */NULL, NULL,
+/* 0x2e */nullptr, nullptr,
/* 0x2f */"PCHIST_$UNIX_PROFIL_CNTL", "x,x,x,x,x,x,x",
/* 0x30 */"XPD_$RESTART", "x,x,x,x,x,x,x",
/* 0x31 */"FILE_$GET_ATTR_INFO", "u,x,x,x,x,x,p",
@@ -802,12 +802,12 @@ static const char* trap8[] = {
/* 0x03 - 0x0A */"VFMT_$WRITE", "s,x,x,x,x,x,x,x,x,x",
/* 0x04 - 0x06 */"VOLX_$DISMOUNT", "x,x,x,x,x,x",
/* 0x05 - 0x06 */"VOLX_$GET_UIDS", "x,x,x,x,x,x",
-/* 0x06 - 0x07 */NULL, NULL,
+/* 0x06 - 0x07 */nullptr, nullptr,
/* 0x07 - 0x07 */"DISK_$PV_ASSIGN", "x,x,x,x,x,x,x",
/* 0x08 - 0x0B */"MSG_$RCV", "x,x,x,x,x,x,x,x,x,x,x",
/* 0x09 - 0x10 */"MSG_$SAR", "x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x",
/* 0x0a - 0x0A */"MSG_$SEND", "x,x,x,x,x,x,x,x,x,x",
-/* 0x0b - 0x06 */NULL, NULL,
+/* 0x0b - 0x06 */nullptr, nullptr,
/* 0x0c - 0x07 */"SMD_$LOAD_CRSR_BITMAP", "x,x,x,x,x,x,x",
/* 0x0d - 0x07 */"SMD_$READ_CRSR_BITMAP", "x,x,x,x,x,x,x",
/* 0x0e - 0x0D */"VFMT_$ENCODE/VFMT_$FORMAT", "s,x,x,x,x,x,x,x,x,x,x,x,x",
@@ -823,22 +823,22 @@ static const char* trap8[] = {
/* 0x18 - 0x0F */"MSG_$RCVI", "x,x,x,x,x,x,x,x,x,x,x,x,x,x,x",
/* 0x19 - 0x0C */"MSG_$RCV_CONTIGI", "x,x,x,x,x,x,x,x,x,x,x,x",
/* 0x1a - 0x11 */"MSG_$SARI", "x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x",
-/* 0x1b - 0x06 */NULL, NULL,
+/* 0x1b - 0x06 */nullptr, nullptr,
/* 0x1c - 0x0E */"MSG_$SEND_HW", "x,x,x,x,x,x,x,x,x,x,x,x,x,x",
/* 0x1d - 0x07 */"PBU_$WIRE_SPECIAL", "x,x,x,x,x,x,x",
/* 0x1e - 0x06 */"PBU_$DMA_START", "x,x,x,x,x,x",
-/* 0x1f - 0x08 */NULL, NULL,
+/* 0x1f - 0x08 */nullptr, nullptr,
/* 0x20 - 0x07 */"MST_$MAP_TOP", "x,x,x,x,x,x,x",
/* 0x21 - 0x08 */"NET_$SEND", "x,x,x,x,x,x,x,x",
/* 0x22 - 0x08 */"NET_$RCV", "x,x,x,x,x,x,x,x",
/* 0x23 - 0x08 */"DIR_$DIR_READU", "u,S,w,x,x,x,x,x",
/* 0x24 - 0x07 */"DIR_$READ_LINKU", "x,x,x,x,x,x,x",
/* 0x25 - 0x07 */"PBU2_$DMA_START", "x,x,x,x,x,x,x",
-/* 0x26 - 0x09 */NULL, NULL,
-/* 0x27 - 0x09 */NULL, NULL,
+/* 0x26 - 0x09 */nullptr, nullptr,
+/* 0x27 - 0x09 */nullptr, nullptr,
/* 0x28 - 0x07 */"PROC2_$COMPLETE_VFORK", "x,x,x,x,x,x,x",
-/* 0x29 - 0x07 */NULL, NULL,
-/* 0x2a - 0x06 */NULL, NULL,
+/* 0x29 - 0x07 */nullptr, nullptr,
+/* 0x2a - 0x06 */nullptr, nullptr,
/* 0x2b - 0x0A */"DIR_$RESOLVE", "S,w,u,u,x,x,x,x,x,x",
/* 0x2c - 0x08 */"VOLX_$MOUNT", "x,x,x,x,x,x,x,x",
/* 0x2d - 0x06 */"ACL_$IMAGE", "x,x,x,x,x,x",
@@ -938,8 +938,8 @@ static const char* get_svc_call(m68000_base_device *m68k, int trap_no,
{
UINT32 sp = REG_A(m68k)[7];
UINT32 pa;
- const char * name = NULL;
- const char * param = NULL;
+ const char * name = nullptr;
+ const char * param = nullptr;
switch (trap_no)
{
@@ -1003,14 +1003,14 @@ static const char* get_svc_call(m68000_base_device *m68k, int trap_no,
sb[0] = '\0';
- if (name == NULL)
+ if (name == nullptr)
{
strcat(sb, "???");
}
else
{
strcat(sb, name);
- if (param != NULL)
+ if (param != nullptr)
{
int i;
strcat(sb, "(");
diff --git a/src/mame/machine/apollo_kbd.cpp b/src/mame/machine/apollo_kbd.cpp
index 6cb767bc67f..d646b9d70c9 100644
--- a/src/mame/machine/apollo_kbd.cpp
+++ b/src/mame/machine/apollo_kbd.cpp
@@ -146,7 +146,7 @@ const char *apollo_kbd_device::cpu_context()
int ms = (t % osd_ticks_per_second()) / 1000;
/* if we have an executing CPU, output data */
- if (cpu != NULL)
+ if (cpu != nullptr)
{
sprintf(statebuf, "%d.%03d %s pc=%08x - %s", s, ms, cpu->tag(),
cpu->safe_pcbase(), tag());
@@ -163,9 +163,9 @@ const char *apollo_kbd_device::cpu_context()
//**************************************************************************
apollo_kbd_device::beeper::beeper() :
- m_device(NULL),
- m_beeper(NULL),
- m_timer(NULL)
+ m_device(nullptr),
+ m_beeper(nullptr),
+ m_timer(nullptr)
{
}
@@ -218,7 +218,7 @@ TIMER_CALLBACK( apollo_kbd_device::beeper::static_beeper_callback )
//**************************************************************************
apollo_kbd_device::mouse::mouse() :
- m_device(NULL)
+ m_device(nullptr)
{
}
diff --git a/src/mame/machine/appldriv.cpp b/src/mame/machine/appldriv.cpp
index 86e2657cf9b..1257b720e23 100644
--- a/src/mame/machine/appldriv.cpp
+++ b/src/mame/machine/appldriv.cpp
@@ -21,7 +21,7 @@
INLINE apple525_floppy_image_device *get_device(device_t *device)
{
- assert(device != NULL);
+ assert(device != nullptr);
assert(device->type() == FLOPPY_APPLE);
return (apple525_floppy_image_device *) downcast<apple525_floppy_image_device *>(device);
@@ -37,7 +37,7 @@ legacy_floppy_image_device *apple525_get_subdevice(device_t *device, int drive)
case 2 : return device->subdevice<legacy_floppy_image_device>(PARENT_FLOPPY_2);
case 3 : return device->subdevice<legacy_floppy_image_device>(PARENT_FLOPPY_3);
}
- return NULL;
+ return nullptr;
}
device_t *apple525_get_device_by_type(device_t *device, int ftype, int drive)
@@ -53,7 +53,7 @@ device_t *apple525_get_device_by_type(device_t *device, int ftype, int drive)
cnt++;
}
}
- return NULL;
+ return nullptr;
}
void apple525_set_enable_lines(device_t *device,int enable_mask)
@@ -166,10 +166,10 @@ static void apple525_disk_set_lines(device_t *device,device_t *image, UINT8 new_
int apple525_get_count(device_t *device)
{
int cnt = 0;
- if ((device->subdevice("^" FLOPPY_0)!=NULL) && (device->subdevice<legacy_floppy_image_device>("^" FLOPPY_0)->floppy_get_drive_type() == FLOPPY_TYPE_APPLE) && (get_device(device->subdevice(PARENT_FLOPPY_0))!=NULL)) cnt++;
- if ((device->subdevice("^" FLOPPY_1)!=NULL) && (device->subdevice<legacy_floppy_image_device>("^" FLOPPY_1)->floppy_get_drive_type() == FLOPPY_TYPE_APPLE) && (get_device(device->subdevice(PARENT_FLOPPY_1))!=NULL)) cnt++;
- if ((device->subdevice("^" FLOPPY_2)!=NULL) && (device->subdevice<legacy_floppy_image_device>("^" FLOPPY_2)->floppy_get_drive_type() == FLOPPY_TYPE_APPLE) && (get_device(device->subdevice(PARENT_FLOPPY_2))!=NULL)) cnt++;
- if ((device->subdevice("^" FLOPPY_3)!=NULL) && (device->subdevice<legacy_floppy_image_device>("^" FLOPPY_3)->floppy_get_drive_type() == FLOPPY_TYPE_APPLE) && (get_device(device->subdevice(PARENT_FLOPPY_3))!=NULL)) cnt++;
+ if ((device->subdevice("^" FLOPPY_0)!=nullptr) && (device->subdevice<legacy_floppy_image_device>("^" FLOPPY_0)->floppy_get_drive_type() == FLOPPY_TYPE_APPLE) && (get_device(device->subdevice(PARENT_FLOPPY_0))!=nullptr)) cnt++;
+ if ((device->subdevice("^" FLOPPY_1)!=nullptr) && (device->subdevice<legacy_floppy_image_device>("^" FLOPPY_1)->floppy_get_drive_type() == FLOPPY_TYPE_APPLE) && (get_device(device->subdevice(PARENT_FLOPPY_1))!=nullptr)) cnt++;
+ if ((device->subdevice("^" FLOPPY_2)!=nullptr) && (device->subdevice<legacy_floppy_image_device>("^" FLOPPY_2)->floppy_get_drive_type() == FLOPPY_TYPE_APPLE) && (get_device(device->subdevice(PARENT_FLOPPY_2))!=nullptr)) cnt++;
+ if ((device->subdevice("^" FLOPPY_3)!=nullptr) && (device->subdevice<legacy_floppy_image_device>("^" FLOPPY_3)->floppy_get_drive_type() == FLOPPY_TYPE_APPLE) && (get_device(device->subdevice(PARENT_FLOPPY_3))!=nullptr)) cnt++;
return cnt;
}
@@ -253,7 +253,7 @@ static device_t *apple525_selected_image(device_t *device)
if (apple525_enable_mask & (1 << i))
return apple525_get_device_by_type(device, FLOPPY_TYPE_APPLE, i);
}
- return NULL;
+ return nullptr;
}
UINT8 apple525_read_data(device_t *device)
diff --git a/src/mame/machine/apple2.cpp b/src/mame/machine/apple2.cpp
index 765f97ad92a..88a2158ab8b 100644
--- a/src/mame/machine/apple2.cpp
+++ b/src/mame/machine/apple2.cpp
@@ -46,7 +46,7 @@ READ8_MEMBER(apple2_state::read_floatingbus)
void apple2_state::apple2_setup_memory(const apple2_memmap_config *config)
{
m_mem_config = *config;
- m_current_meminfo = NULL;
+ m_current_meminfo = nullptr;
apple2_update_memory();
}
@@ -91,11 +91,11 @@ void apple2_state::apple2_update_memory()
|| (meminfo.read_mem != m_current_meminfo[i].read_mem)
|| (meminfo.read_handler != m_current_meminfo[i].read_handler))
{
- rbase = NULL;
+ rbase = nullptr;
sprintf(rbank,"bank%d",bank);
begin = m_mem_config.memmap[i].begin;
end_r = m_mem_config.memmap[i].end;
- rh = NULL;
+ rh = nullptr;
LOG(("apple2_update_memory(): Updating RD {%06X..%06X} [#%02d] --> %08X\n",
begin, end_r, bank, meminfo.read_mem));
@@ -183,14 +183,14 @@ void apple2_state::apple2_update_memory()
|| (meminfo.write_mem != m_current_meminfo[i].write_mem)
|| (meminfo.write_handler != m_current_meminfo[i].write_handler))
{
- wbase = NULL;
+ wbase = nullptr;
if (bank_disposition == A2MEM_MONO)
sprintf(wbank,"bank%d",bank);
else if (bank_disposition == A2MEM_DUAL)
sprintf(wbank,"bank%d",bank+1);
begin = m_mem_config.memmap[i].begin;
end_w = m_mem_config.memmap[i].end;
- wh = NULL;
+ wh = nullptr;
LOG(("apple2_update_memory(): Updating WR {%06X..%06X} [#%02d] --> %08X\n",
begin, end_w, bank, meminfo.write_mem));
@@ -402,7 +402,7 @@ READ8_MEMBER(apple2_state::apple2_c080_r)
slotdevice = m_a2bus->get_a2bus_card(slot);
/* and if we can, read from the slot */
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
return slotdevice->read_c0nx(space, offset % 0x10);
}
@@ -506,7 +506,7 @@ WRITE8_MEMBER(apple2_state::apple2_c080_w)
slotdevice = m_a2bus->get_a2bus_card(slot);
/* and if we can, write to the slot */
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
slotdevice->write_c0nx(space, offset % 0x10, data);
}
@@ -539,7 +539,7 @@ READ8_MEMBER(apple2_state::apple2_c1xx_r )
slotnum = ((offset>>8) & 0xf) + 1;
slotdevice = m_a2bus->get_a2bus_card(slotnum);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
if ((slotdevice->take_c800()) && (!space.debugger_access()))
{
@@ -569,7 +569,7 @@ WRITE8_MEMBER(apple2_state::apple2_c1xx_w )
slotdevice = m_a2bus->get_a2bus_card(slotnum);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
slotdevice->write_cnxx(space, offset&0xff, data);
}
@@ -589,7 +589,7 @@ READ8_MEMBER(apple2_state::apple2_c3xx_r )
slotdevice = m_a2bus->get_a2bus_card(slotnum);
// is a card installed in this slot?
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
if ((slotdevice->take_c800()) && (!space.debugger_access()))
{
@@ -617,7 +617,7 @@ WRITE8_MEMBER(apple2_state::apple2_c3xx_w )
slotnum = 3;
slotdevice = m_a2bus->get_a2bus_card(slotnum);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
if ((slotdevice->take_c800()) && (!space.debugger_access()))
{
@@ -643,7 +643,7 @@ READ8_MEMBER(apple2_state::apple2_c4xx_r )
slotdevice = m_a2bus->get_a2bus_card(slotnum);
// is a card installed in this slot?
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
if (slotdevice->take_c800() && (m_a2_cnxx_slot != slotnum) && (!space.debugger_access()))
{
@@ -670,7 +670,7 @@ WRITE8_MEMBER ( apple2_state::apple2_c4xx_w )
slotnum = ((offset>>8) & 0xf) + 4;
slotdevice = m_a2bus->get_a2bus_card(slotnum);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
if ((slotdevice->take_c800()) && (!space.debugger_access()))
{
@@ -716,7 +716,7 @@ READ8_MEMBER(apple2_state::apple2_c800_r )
slotdevice = m_a2bus->get_a2bus_card(m_a2_cnxx_slot);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
return slotdevice->read_c800(space, offset&0xfff);
}
@@ -730,7 +730,7 @@ WRITE8_MEMBER(apple2_state::apple2_c800_w )
slotdevice = m_a2bus->get_a2bus_card(m_a2_cnxx_slot);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
slotdevice->write_c800(space, offset&0xfff, data);
}
@@ -742,7 +742,7 @@ READ8_MEMBER(apple2_state::apple2_ce00_r )
slotdevice = m_a2bus->get_a2bus_card(m_a2_cnxx_slot);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
return slotdevice->read_c800(space, (offset&0xfff) + 0x600);
}
@@ -756,7 +756,7 @@ WRITE8_MEMBER(apple2_state::apple2_ce00_w )
slotdevice = m_a2bus->get_a2bus_card(m_a2_cnxx_slot);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
slotdevice->write_c800(space, (offset&0xfff)+0x600, data);
}
@@ -768,7 +768,7 @@ READ8_MEMBER(apple2_state::apple2_inh_d000_r )
slotdevice = m_a2bus->get_a2bus_card(m_inh_slot);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
return slotdevice->read_inh_rom(space, offset & 0xfff);
}
@@ -782,7 +782,7 @@ WRITE8_MEMBER(apple2_state::apple2_inh_d000_w )
slotdevice = m_a2bus->get_a2bus_card(m_inh_slot);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
return slotdevice->write_inh_rom(space, offset & 0xfff, data);
}
@@ -794,7 +794,7 @@ READ8_MEMBER(apple2_state::apple2_inh_e000_r )
slotdevice = m_a2bus->get_a2bus_card(m_inh_slot);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
return slotdevice->read_inh_rom(space, (offset & 0x1fff) + 0x1000);
}
@@ -808,7 +808,7 @@ WRITE8_MEMBER(apple2_state::apple2_inh_e000_w )
slotdevice = m_a2bus->get_a2bus_card(m_inh_slot);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
slotdevice->write_inh_rom(space, (offset & 0x1fff) + 0x1000, data);
}
@@ -1308,8 +1308,8 @@ void apple2_state::machine_reset()
int apple2_state::a2_no_ctrl_reset()
{
- return (((m_kbrepeat != NULL) && (m_resetdip == NULL)) ||
- ((m_resetdip != NULL) && !m_resetdip->read()));
+ return (((m_kbrepeat != nullptr) && (m_resetdip == nullptr)) ||
+ ((m_resetdip != nullptr) && !m_resetdip->read()));
}
/* -----------------------------------------------------------------------
@@ -2235,9 +2235,9 @@ void apple2_state::apple2_init_common()
m_rom = memregion("maincpu")->base();
m_rom_length = memregion("maincpu")->bytes() & ~0xFFF;
m_slot_length = memregion("maincpu")->bytes() - m_rom_length;
- m_slot_ram = (m_slot_length > 0) ? &m_rom[m_rom_length] : NULL;
+ m_slot_ram = (m_slot_length > 0) ? &m_rom[m_rom_length] : nullptr;
- m_auxslotdevice = NULL;
+ m_auxslotdevice = nullptr;
if (m_machinetype == APPLE_IIE || m_machinetype == TK3000)
{
m_auxslotdevice = m_a2eauxslot->get_a2eauxslot_card();
@@ -2283,14 +2283,14 @@ MACHINE_START_MEMBER(apple2_state,apple2c)
{
m_machinetype = APPLE_IIC;
- apple2eplus_init_common((void *)NULL);
+ apple2eplus_init_common((void *)nullptr);
}
MACHINE_START_MEMBER(apple2_state,tk3000)
{
m_machinetype = TK3000; // enhanced IIe clone with Z80 keyboard scanner subcpu
- apple2eplus_init_common((void *)NULL);
+ apple2eplus_init_common((void *)nullptr);
}
MACHINE_START_MEMBER(apple2_state,apple2cp)
@@ -2322,7 +2322,7 @@ MACHINE_START_MEMBER(apple2_state,apple2e)
memset(&mem_cfg, 0, sizeof(mem_cfg));
mem_cfg.first_bank = 1;
mem_cfg.memmap = apple2_memmap_entries;
- mem_cfg.auxmem = (UINT8*)NULL;
+ mem_cfg.auxmem = (UINT8*)nullptr;
apple2_setup_memory(&mem_cfg);
}
@@ -2353,14 +2353,14 @@ MACHINE_START_MEMBER(apple2_state,laser128)
memset(&mem_cfg, 0, sizeof(mem_cfg));
mem_cfg.first_bank = 1;
mem_cfg.memmap = apple2_memmap_entries;
- mem_cfg.auxmem = (UINT8*)NULL;
+ mem_cfg.auxmem = (UINT8*)nullptr;
apple2_setup_memory(&mem_cfg);
}
MACHINE_START_MEMBER(apple2_state,apple2orig)
{
apple2_memmap_config mem_cfg;
- void *apple2cp_ce00_ram = NULL;
+ void *apple2cp_ce00_ram = nullptr;
// II and II+ have no internal ROM or internal slot 3 h/w, so don't allow these states
m_flags_mask = VAR_INTCXROM|VAR_SLOTC3ROM;
@@ -2380,7 +2380,7 @@ MACHINE_START_MEMBER(apple2_state,apple2orig)
MACHINE_START_MEMBER(apple2_state,space84)
{
apple2_memmap_config mem_cfg;
- void *apple2cp_ce00_ram = NULL;
+ void *apple2cp_ce00_ram = nullptr;
// II and II+ have no internal ROM or internal slot 3 h/w, so don't allow these states
m_flags_mask = VAR_INTCXROM|VAR_SLOTC3ROM;
@@ -2400,7 +2400,7 @@ MACHINE_START_MEMBER(apple2_state,space84)
MACHINE_START_MEMBER(apple2_state,laba2p)
{
apple2_memmap_config mem_cfg;
- void *apple2cp_ce00_ram = NULL;
+ void *apple2cp_ce00_ram = nullptr;
// II and II+ have no internal ROM or internal slot 3 h/w, so don't allow these states
m_flags_mask = VAR_INTCXROM|VAR_SLOTC3ROM;
@@ -2432,7 +2432,7 @@ MACHINE_START_MEMBER(apple2_state,tk2000)
memset(&mem_cfg, 0, sizeof(mem_cfg));
mem_cfg.first_bank = 1;
mem_cfg.memmap = tk2000_memmap_entries;
- mem_cfg.auxmem = (UINT8*)NULL;
+ mem_cfg.auxmem = (UINT8*)nullptr;
apple2_setup_memory(&mem_cfg);
}
diff --git a/src/mame/machine/apple2gs.cpp b/src/mame/machine/apple2gs.cpp
index 4f7f64f0f7c..132ed6e8dca 100644
--- a/src/mame/machine/apple2gs.cpp
+++ b/src/mame/machine/apple2gs.cpp
@@ -247,7 +247,7 @@ const char *apple2gs_state::apple2gs_irq_name(UINT16 irq_mask)
case IRQ_DOC: return "IRQ_DOC";
case IRQ_SLOT: return "IRQ_SLOT";
}
- return NULL;
+ return nullptr;
}
void apple2gs_state::apple2gs_add_irq(UINT16 irq_mask)
@@ -1638,7 +1638,7 @@ UINT8 apple2gs_state::apple2gs_xxCxxx_r(address_space &space, offs_t address)
else
{
// accessing a slot mapped to "Your Card", C800 should belong to that card
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
if (slotdevice->take_c800())
{
@@ -1655,7 +1655,7 @@ UINT8 apple2gs_state::apple2gs_xxCxxx_r(address_space &space, offs_t address)
}
else // C800-CFFF, not cards
{
- slotdevice = NULL;
+ slotdevice = nullptr;
// if CFFF accessed, reset C800 area to internal ROM
if(!space.debugger_access())
@@ -1730,7 +1730,7 @@ void apple2gs_state::apple2gs_xxCxxx_w(address_space &space, offs_t address, UIN
else
{
// accessing a slot mapped to "Your Card", C800 should belong to that card if it can take it
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
if (slotdevice->take_c800())
{
@@ -1744,7 +1744,7 @@ void apple2gs_state::apple2gs_xxCxxx_w(address_space &space, offs_t address, UIN
}
else // C800-CFFF, not cards
{
- slotdevice = NULL;
+ slotdevice = nullptr;
// if CFFF accessed, reset C800 area to internal ROM
if ((address & 0xfff) == 0xfff)
@@ -1908,7 +1908,7 @@ MACHINE_RESET_MEMBER(apple2gs_state,apple2gs)
// call "base class" machine reset to set up m_rambase and the language card
machine_reset();
- m_cur_slot6_image = NULL;
+ m_cur_slot6_image = nullptr;
m_newvideo = 0x00;
m_vgcint = 0x00;
m_langsel = 0x00;
@@ -1961,7 +1961,7 @@ MACHINE_START_MEMBER(apple2gs_state,apple2gscommon)
apple2gs_refresh_delegates();
m_machinetype = APPLE_IIGS;
- apple2eplus_init_common(NULL);
+ apple2eplus_init_common(nullptr);
/* set up Apple IIgs vectoring */
m_maincpu->set_read_vector_callback(read8_delegate(FUNC(apple2gs_state::apple2gs_read_vector),this));
diff --git a/src/mame/machine/apple3.cpp b/src/mame/machine/apple3.cpp
index 8df76e3de4a..69db605aa36 100644
--- a/src/mame/machine/apple3.cpp
+++ b/src/mame/machine/apple3.cpp
@@ -196,7 +196,7 @@ READ8_MEMBER(apple3_state::apple3_c0xx_r)
case 0x98: case 0x99: case 0x9a: case 0x9b:
case 0x9c: case 0x9d: case 0x9e: case 0x9f:
slotdevice = m_a2bus->get_a2bus_card(1);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
result = slotdevice->read_c0nx(space, offset&0xf);
}
@@ -207,7 +207,7 @@ READ8_MEMBER(apple3_state::apple3_c0xx_r)
case 0xa8: case 0xa9: case 0xaa: case 0xab:
case 0xac: case 0xad: case 0xae: case 0xaf:
slotdevice = m_a2bus->get_a2bus_card(2);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
result = slotdevice->read_c0nx(space, offset&0xf);
}
@@ -218,7 +218,7 @@ READ8_MEMBER(apple3_state::apple3_c0xx_r)
case 0xb8: case 0xb9: case 0xba: case 0xbb:
case 0xbc: case 0xbd: case 0xbe: case 0xbf:
slotdevice = m_a2bus->get_a2bus_card(3);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
result = slotdevice->read_c0nx(space, offset&0xf);
}
@@ -229,7 +229,7 @@ READ8_MEMBER(apple3_state::apple3_c0xx_r)
case 0xc8: case 0xc9: case 0xca: case 0xcb:
case 0xcc: case 0xcd: case 0xce: case 0xcf:
slotdevice = m_a2bus->get_a2bus_card(4);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
result = slotdevice->read_c0nx(space, offset&0xf);
}
@@ -351,7 +351,7 @@ WRITE8_MEMBER(apple3_state::apple3_c0xx_w)
case 0x98: case 0x99: case 0x9a: case 0x9b:
case 0x9c: case 0x9d: case 0x9e: case 0x9f:
slotdevice = m_a2bus->get_a2bus_card(1);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
slotdevice->write_c0nx(space, offset&0xf, data);
}
@@ -362,7 +362,7 @@ WRITE8_MEMBER(apple3_state::apple3_c0xx_w)
case 0xa8: case 0xa9: case 0xaa: case 0xab:
case 0xac: case 0xad: case 0xae: case 0xaf:
slotdevice = m_a2bus->get_a2bus_card(2);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
slotdevice->write_c0nx(space, offset&0xf, data);
}
@@ -373,7 +373,7 @@ WRITE8_MEMBER(apple3_state::apple3_c0xx_w)
case 0xb8: case 0xb9: case 0xba: case 0xbb:
case 0xbc: case 0xbd: case 0xbe: case 0xbf:
slotdevice = m_a2bus->get_a2bus_card(3);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
slotdevice->write_c0nx(space, offset&0xf, data);
}
@@ -384,7 +384,7 @@ WRITE8_MEMBER(apple3_state::apple3_c0xx_w)
case 0xc8: case 0xc9: case 0xca: case 0xcb:
case 0xcc: case 0xcd: case 0xce: case 0xcf:
slotdevice = m_a2bus->get_a2bus_card(4);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
slotdevice->write_c0nx(space, offset&0xf, data);
}
@@ -642,7 +642,7 @@ MACHINE_RESET_MEMBER(apple3_state,apple3)
UINT8 *apple3_state::apple3_get_indexed_addr(offs_t offset)
{
- UINT8 *result = NULL;
+ UINT8 *result = nullptr;
// m_indir_bank is guaranteed to be between 0x80 and 0x8f
if (m_indir_bank == 0x8f)
@@ -810,7 +810,7 @@ READ8_MEMBER(apple3_state::apple3_memory_r)
/* now identify the device */
device_a2bus_card_interface *slotdevice = m_a2bus->get_a2bus_card((offset>>8) & 0x7);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
if (slotdevice->take_c800())
{
@@ -842,7 +842,7 @@ READ8_MEMBER(apple3_state::apple3_memory_r)
{
device_a2bus_card_interface *slotdevice = m_a2bus->get_a2bus_card(m_cnxx_slot);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
rv = slotdevice->read_c800(space, offset&0x7ff);
}
@@ -938,7 +938,7 @@ WRITE8_MEMBER(apple3_state::apple3_memory_w)
/* now identify the device */
device_a2bus_card_interface *slotdevice = m_a2bus->get_a2bus_card((offset>>8) & 0x7);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
if (slotdevice->take_c800())
{
@@ -976,7 +976,7 @@ WRITE8_MEMBER(apple3_state::apple3_memory_w)
{
device_a2bus_card_interface *slotdevice = m_a2bus->get_a2bus_card(m_cnxx_slot);
- if (slotdevice != NULL)
+ if (slotdevice != nullptr)
{
slotdevice->write_c800(space, offset&0x7ff, data);
}
diff --git a/src/mame/machine/applefdc.cpp b/src/mame/machine/applefdc.cpp
index dac524308ba..014546b0f85 100644
--- a/src/mame/machine/applefdc.cpp
+++ b/src/mame/machine/applefdc.cpp
@@ -174,9 +174,9 @@ void applefdc_base_device::device_timer(emu_timer &timer, device_timer_id id, in
const applefdc_interface *applefdc_base_device::get_interface()
{
- static const applefdc_interface dummy_interface = {0, };
+ static const applefdc_interface dummy_interface = {nullptr, };
- return (static_config() != NULL)
+ return (static_config() != nullptr)
? (const applefdc_interface *) static_config()
: &dummy_interface;
}
@@ -331,7 +331,7 @@ void applefdc_base_device::write_reg(UINT8 data)
logerror("applefdc_write_reg(): latch mode off not implemented\n");
}
- if (intf->write_data != NULL)
+ if (intf->write_data != nullptr)
intf->write_data(this, data);
}
break;
@@ -366,7 +366,7 @@ void applefdc_base_device::turn_motor_onoff(bool status)
}
/* invoke callback, if present */
- if (intf->set_enable_lines != NULL)
+ if (intf->set_enable_lines != nullptr)
intf->set_enable_lines(this, enable_lines);
if (LOG_APPLEFDC_EXTRA)
@@ -406,7 +406,7 @@ void applefdc_base_device::iwm_access(int offset)
(offset & 1) ? "setting" : "clearing", lines[offset >> 1], m_lines);
}
- if ((offset < 0x08) && (intf->set_lines != NULL))
+ if ((offset < 0x08) && (intf->set_lines != nullptr))
intf->set_lines(this, m_lines & 0x0f);
switch(offset)
@@ -424,13 +424,13 @@ void applefdc_base_device::iwm_access(int offset)
case 0x0A:
/* turn off IWM_DRIVE */
- if ((m_lines & IWM_MOTOR) && (intf->set_enable_lines != NULL))
+ if ((m_lines & IWM_MOTOR) && (intf->set_enable_lines != nullptr))
intf->set_enable_lines(this, 1);
break;
case 0x0B:
/* turn on IWM_DRIVE */
- if ((m_lines & IWM_MOTOR) && (intf->set_enable_lines != NULL))
+ if ((m_lines & IWM_MOTOR) && (intf->set_enable_lines != nullptr))
intf->set_enable_lines(this, 2);
break;
}
@@ -463,7 +463,7 @@ UINT8 applefdc_base_device::read(UINT8 offset)
case 0x0C:
if (m_lines & IWM_Q7)
{
- if (intf->write_data != NULL)
+ if (intf->write_data != nullptr)
intf->write_data(this, m_write_byte);
result = 0;
}
@@ -525,7 +525,7 @@ void applefdc_base_device::write(UINT8 offset, UINT8 data)
case 0x0C:
if (m_lines & IWM_Q7)
{
- if (intf->write_data != NULL)
+ if (intf->write_data != nullptr)
intf->write_data(this, m_write_byte);
}
break;
diff --git a/src/mame/machine/apricotkb_hle.cpp b/src/mame/machine/apricotkb_hle.cpp
index 6950033c79f..7bf5531454c 100644
--- a/src/mame/machine/apricotkb_hle.cpp
+++ b/src/mame/machine/apricotkb_hle.cpp
@@ -70,37 +70,37 @@ const device_type APRICOT_KEYBOARD_HLE = &device_creator<apricot_keyboard_hle_de
static INPUT_PORTS_START( keyboard )
PORT_START("keyboard_0")
PORT_BIT(1 << 0, IP_ACTIVE_HIGH, IPT_UNUSED)
- APRICOT_KEY( 1, 0) PORT_CODE(KEYCODE_F7) PORT_CHAR(UCHAR_MAMEKEY(F7)) PORT_NAME("Help")
- APRICOT_KEY( 2, 0) PORT_CODE(KEYCODE_F8) PORT_CHAR(UCHAR_MAMEKEY(F8)) PORT_NAME("Undo")
- APRICOT_KEY( 3, 0) PORT_CODE(KEYCODE_F9) PORT_CHAR(UCHAR_MAMEKEY(F9)) PORT_NAME("Repeat")
- APRICOT_KEY( 4, 0) PORT_CODE(KEYCODE_F10) PORT_CHAR(UCHAR_MAMEKEY(F10)) PORT_NAME("Calc")
- APRICOT_KEY( 5, 0) PORT_CODE(KEYCODE_PRTSCR) PORT_CHAR(UCHAR_MAMEKEY(PRTSCR)) PORT_NAME("Print")
- APRICOT_KEY( 6, 0) PORT_CODE(KEYCODE_CANCEL) PORT_CHAR(UCHAR_MAMEKEY(CANCEL)) PORT_NAME("Intr")
- APRICOT_KEY( 7, 0) PORT_CODE(KEYCODE_F11) PORT_CHAR(UCHAR_MAMEKEY(F11)) PORT_NAME("Menu")
- APRICOT_KEY( 8, 0) PORT_CODE(KEYCODE_F12) PORT_CHAR(UCHAR_MAMEKEY(F12)) PORT_NAME("Finish")
- APRICOT_KEY( 9, 0) PORT_CODE(KEYCODE_F1) PORT_CHAR(UCHAR_MAMEKEY(F1)) PORT_NAME("Function 1")
- APRICOT_KEY(10, 0) PORT_CODE(KEYCODE_F2) PORT_CHAR(UCHAR_MAMEKEY(F2)) PORT_NAME("Function 2")
- APRICOT_KEY(11, 0) PORT_CODE(KEYCODE_F3) PORT_CHAR(UCHAR_MAMEKEY(F3)) PORT_NAME("Function 3")
- APRICOT_KEY(12, 0) PORT_CODE(KEYCODE_F4) PORT_CHAR(UCHAR_MAMEKEY(F4)) PORT_NAME("Function 4")
- APRICOT_KEY(13, 0) PORT_CODE(KEYCODE_F5) PORT_CHAR(UCHAR_MAMEKEY(F5)) PORT_NAME("Function 5")
- APRICOT_KEY(14, 0) PORT_CODE(KEYCODE_F6) PORT_CHAR(UCHAR_MAMEKEY(F6)) PORT_NAME("Function 6")
- APRICOT_KEY(15, 0) PORT_CODE(KEYCODE_BACKSLASH) PORT_CHAR('\\') PORT_CHAR('^')
- APRICOT_KEY(16, 0) PORT_CODE(KEYCODE_1) PORT_CHAR('1') PORT_CHAR('!')
- APRICOT_KEY(17, 0) PORT_CODE(KEYCODE_2) PORT_CHAR('2') PORT_CHAR('@')
- APRICOT_KEY(18, 0) PORT_CODE(KEYCODE_3) PORT_CHAR('3') PORT_CHAR('#')
- APRICOT_KEY(19, 0) PORT_CODE(KEYCODE_4) PORT_CHAR('4') PORT_CHAR(0xa3) // pound
- APRICOT_KEY(20, 0) PORT_CODE(KEYCODE_5) PORT_CHAR('5') PORT_CHAR('%')
- APRICOT_KEY(21, 0) PORT_CODE(KEYCODE_6) PORT_CHAR('6') PORT_CHAR('$')
- APRICOT_KEY(22, 0) PORT_CODE(KEYCODE_7) PORT_CHAR('7') PORT_CHAR('&')
- APRICOT_KEY(23, 0) PORT_CODE(KEYCODE_8) PORT_CHAR('8') PORT_CHAR('*')
- APRICOT_KEY(24, 0) PORT_CODE(KEYCODE_9) PORT_CHAR('9') PORT_CHAR('(')
- APRICOT_KEY(25, 0) PORT_CODE(KEYCODE_0) PORT_CHAR('0') PORT_CHAR(')')
- APRICOT_KEY(26, 0) PORT_CODE(KEYCODE_MINUS) PORT_CHAR('-') PORT_CHAR('_')
- APRICOT_KEY(27, 0) PORT_CODE(KEYCODE_EQUALS) PORT_CHAR('=') PORT_CHAR('+')
- APRICOT_KEY(28, 0) PORT_CODE(KEYCODE_BACKSPACE) PORT_CHAR(9)
+ APRICOT_KEY( 1, nullptr) PORT_CODE(KEYCODE_F7) PORT_CHAR(UCHAR_MAMEKEY(F7)) PORT_NAME("Help")
+ APRICOT_KEY( 2, nullptr) PORT_CODE(KEYCODE_F8) PORT_CHAR(UCHAR_MAMEKEY(F8)) PORT_NAME("Undo")
+ APRICOT_KEY( 3, nullptr) PORT_CODE(KEYCODE_F9) PORT_CHAR(UCHAR_MAMEKEY(F9)) PORT_NAME("Repeat")
+ APRICOT_KEY( 4, nullptr) PORT_CODE(KEYCODE_F10) PORT_CHAR(UCHAR_MAMEKEY(F10)) PORT_NAME("Calc")
+ APRICOT_KEY( 5, nullptr) PORT_CODE(KEYCODE_PRTSCR) PORT_CHAR(UCHAR_MAMEKEY(PRTSCR)) PORT_NAME("Print")
+ APRICOT_KEY( 6, nullptr) PORT_CODE(KEYCODE_CANCEL) PORT_CHAR(UCHAR_MAMEKEY(CANCEL)) PORT_NAME("Intr")
+ APRICOT_KEY( 7, nullptr) PORT_CODE(KEYCODE_F11) PORT_CHAR(UCHAR_MAMEKEY(F11)) PORT_NAME("Menu")
+ APRICOT_KEY( 8, nullptr) PORT_CODE(KEYCODE_F12) PORT_CHAR(UCHAR_MAMEKEY(F12)) PORT_NAME("Finish")
+ APRICOT_KEY( 9, nullptr) PORT_CODE(KEYCODE_F1) PORT_CHAR(UCHAR_MAMEKEY(F1)) PORT_NAME("Function 1")
+ APRICOT_KEY(10, nullptr) PORT_CODE(KEYCODE_F2) PORT_CHAR(UCHAR_MAMEKEY(F2)) PORT_NAME("Function 2")
+ APRICOT_KEY(11, nullptr) PORT_CODE(KEYCODE_F3) PORT_CHAR(UCHAR_MAMEKEY(F3)) PORT_NAME("Function 3")
+ APRICOT_KEY(12, nullptr) PORT_CODE(KEYCODE_F4) PORT_CHAR(UCHAR_MAMEKEY(F4)) PORT_NAME("Function 4")
+ APRICOT_KEY(13, nullptr) PORT_CODE(KEYCODE_F5) PORT_CHAR(UCHAR_MAMEKEY(F5)) PORT_NAME("Function 5")
+ APRICOT_KEY(14, nullptr) PORT_CODE(KEYCODE_F6) PORT_CHAR(UCHAR_MAMEKEY(F6)) PORT_NAME("Function 6")
+ APRICOT_KEY(15, nullptr) PORT_CODE(KEYCODE_BACKSLASH) PORT_CHAR('\\') PORT_CHAR('^')
+ APRICOT_KEY(16, nullptr) PORT_CODE(KEYCODE_1) PORT_CHAR('1') PORT_CHAR('!')
+ APRICOT_KEY(17, nullptr) PORT_CODE(KEYCODE_2) PORT_CHAR('2') PORT_CHAR('@')
+ APRICOT_KEY(18, nullptr) PORT_CODE(KEYCODE_3) PORT_CHAR('3') PORT_CHAR('#')
+ APRICOT_KEY(19, nullptr) PORT_CODE(KEYCODE_4) PORT_CHAR('4') PORT_CHAR(0xa3) // pound
+ APRICOT_KEY(20, nullptr) PORT_CODE(KEYCODE_5) PORT_CHAR('5') PORT_CHAR('%')
+ APRICOT_KEY(21, nullptr) PORT_CODE(KEYCODE_6) PORT_CHAR('6') PORT_CHAR('$')
+ APRICOT_KEY(22, nullptr) PORT_CODE(KEYCODE_7) PORT_CHAR('7') PORT_CHAR('&')
+ APRICOT_KEY(23, nullptr) PORT_CODE(KEYCODE_8) PORT_CHAR('8') PORT_CHAR('*')
+ APRICOT_KEY(24, nullptr) PORT_CODE(KEYCODE_9) PORT_CHAR('9') PORT_CHAR('(')
+ APRICOT_KEY(25, nullptr) PORT_CODE(KEYCODE_0) PORT_CHAR('0') PORT_CHAR(')')
+ APRICOT_KEY(26, nullptr) PORT_CODE(KEYCODE_MINUS) PORT_CHAR('-') PORT_CHAR('_')
+ APRICOT_KEY(27, nullptr) PORT_CODE(KEYCODE_EQUALS) PORT_CHAR('=') PORT_CHAR('+')
+ APRICOT_KEY(28, nullptr) PORT_CODE(KEYCODE_BACKSPACE) PORT_CHAR(9)
PORT_BIT(1 << 29, IP_ACTIVE_HIGH, IPT_UNUSED) // actually a dedicated % key
- APRICOT_KEY(30, 0) PORT_CODE(KEYCODE_ASTERISK) PORT_CHAR(UCHAR_MAMEKEY(ASTERISK))
- APRICOT_KEY(31, 0) PORT_CODE(KEYCODE_SLASH_PAD) PORT_CHAR(UCHAR_MAMEKEY(SLASH_PAD))
+ APRICOT_KEY(30, nullptr) PORT_CODE(KEYCODE_ASTERISK) PORT_CHAR(UCHAR_MAMEKEY(ASTERISK))
+ APRICOT_KEY(31, nullptr) PORT_CODE(KEYCODE_SLASH_PAD) PORT_CHAR(UCHAR_MAMEKEY(SLASH_PAD))
PORT_START("keyboard_1")
APRICOT_KEY( 0, 1) PORT_CODE(KEYCODE_MINUS_PAD) PORT_CHAR(UCHAR_MAMEKEY(MINUS_PAD))
diff --git a/src/mame/machine/archimds.cpp b/src/mame/machine/archimds.cpp
index ad5b6f70f85..b22ef889e37 100644
--- a/src/mame/machine/archimds.cpp
+++ b/src/mame/machine/archimds.cpp
@@ -487,7 +487,7 @@ void archimedes_state::latch_timer_cnt(int tmr)
bool archimedes_state::check_floppy_ready()
{
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if(!m_fdc)
return false;
@@ -859,12 +859,12 @@ WRITE32_MEMBER(archimedes_state::archimedes_ioc_w)
/*
-x-- ---- In Use Control (floppy?)
*/
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (!(data & 1)) { m_floppy_select = 0; floppy = m_floppy0->get_device(); }
if (!(data & 2)) { m_floppy_select = 1; floppy = m_floppy1->get_device(); }
- if (!(data & 4)) { m_floppy_select = 2; floppy = NULL; } // floppy 2
- if (!(data & 8)) { m_floppy_select = 3; floppy = NULL; } // floppy 3
+ if (!(data & 4)) { m_floppy_select = 2; floppy = nullptr; } // floppy 2
+ if (!(data & 8)) { m_floppy_select = 3; floppy = nullptr; } // floppy 3
m_fdc->set_floppy(floppy);
diff --git a/src/mame/machine/asic65.cpp b/src/mame/machine/asic65.cpp
index 978443f497c..5674adfd49e 100644
--- a/src/mame/machine/asic65.cpp
+++ b/src/mame/machine/asic65.cpp
@@ -100,7 +100,7 @@ asic65_device::asic65_device(const machine_config &mconfig, const char *tag, dev
m_xflg(0),
m_68data(0),
m_tdata(0),
- m_log(NULL)
+ m_log(nullptr)
{
for (int i = 0; i < 32; i++)
{
diff --git a/src/mame/machine/asteroid.cpp b/src/mame/machine/asteroid.cpp
index 37e252e6bd0..e8e01c5f065 100644
--- a/src/mame/machine/asteroid.cpp
+++ b/src/mame/machine/asteroid.cpp
@@ -120,7 +120,7 @@ WRITE8_MEMBER(asteroid_state::astdelux_led_w)
void asteroid_state::machine_start()
{
/* configure RAM banks if present (not on llander) */
- if (m_ram1.target() != NULL)
+ if (m_ram1.target() != nullptr)
{
UINT8 *ram1 = reinterpret_cast<UINT8 *>(memshare("ram1")->ptr());
UINT8 *ram2 = reinterpret_cast<UINT8 *>(memshare("ram2")->ptr());
@@ -139,7 +139,7 @@ void asteroid_state::machine_reset()
m_dvg->reset_w(m_maincpu->space(AS_PROGRAM), 0, 0);
/* reset RAM banks if present */
- if (m_ram1.target() != NULL)
+ if (m_ram1.target() != nullptr)
{
m_ram1->set_entry(0);
m_ram2->set_entry(0);
diff --git a/src/mame/machine/atarifdc.cpp b/src/mame/machine/atarifdc.cpp
index d3c70c12543..0249ba31e7e 100644
--- a/src/mame/machine/atarifdc.cpp
+++ b/src/mame/machine/atarifdc.cpp
@@ -136,7 +136,7 @@ void atari_fdc_device::atari_load_proc(device_image_interface &image)
if( size <= 0 )
{
- m_drv[id].image = NULL;
+ m_drv[id].image = nullptr;
return;
}
@@ -147,7 +147,7 @@ void atari_fdc_device::atari_load_proc(device_image_interface &image)
ext = image.filetype();
// hack alert, this means we can only load ATR via the softlist at the moment, image.filetype reutrns NULL :/
- if (image.software_entry() != NULL) ext="ATR";
+ if (image.software_entry() != nullptr) ext="ATR";
/* no extension: assume XFD format (no header) */
if (!ext)
@@ -749,7 +749,7 @@ legacy_floppy_image_device *atari_fdc_device::atari_floppy_get_device_child(int
case 2 : return subdevice<legacy_floppy_image_device>(FLOPPY_2);
case 3 : return subdevice<legacy_floppy_image_device>(FLOPPY_3);
}
- return NULL;
+ return nullptr;
}
const device_type ATARI_FDC = &device_creator<atari_fdc_device>;
diff --git a/src/mame/machine/atarigen.cpp b/src/mame/machine/atarigen.cpp
index 639726f0528..05127cb1edd 100644
--- a/src/mame/machine/atarigen.cpp
+++ b/src/mame/machine/atarigen.cpp
@@ -44,7 +44,7 @@ inline const atarigen_screen_timer *get_screen_timer(screen_device &screen)
return &state->m_screen_timer[i];
fatalerror("Unexpected: no atarivc_eof_update_timer for screen '%s'\n", screen.tag());
- return NULL;
+ return nullptr;
}
@@ -62,9 +62,9 @@ const device_type ATARI_SOUND_COMM = &device_creator<atari_sound_comm_device>;
atari_sound_comm_device::atari_sound_comm_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: device_t(mconfig, ATARI_SOUND_COMM, "Atari Sound Communications", tag, owner, clock, "atarscom", __FILE__),
- m_sound_cpu_tag(NULL),
+ m_sound_cpu_tag(nullptr),
m_main_int_cb(*this),
- m_sound_cpu(NULL),
+ m_sound_cpu(nullptr),
m_main_to_sound_ready(false),
m_sound_to_main_ready(false),
m_main_to_sound_data(0),
@@ -93,10 +93,10 @@ void atari_sound_comm_device::static_set_sound_cpu(device_t &device, const char
void atari_sound_comm_device::device_start()
{
// find the sound CPU
- if (m_sound_cpu_tag == NULL)
+ if (m_sound_cpu_tag == nullptr)
throw emu_fatalerror("No sound CPU specified!");
m_sound_cpu = siblingdevice<m6502_device>(m_sound_cpu_tag);
- if (m_sound_cpu == NULL)
+ if (m_sound_cpu == nullptr)
throw emu_fatalerror("Sound CPU '%s' not found!", m_sound_cpu_tag);
// resolve callbacks
@@ -362,9 +362,9 @@ atari_vad_device::atari_vad_device(const machine_config &mconfig, const char *ta
m_playfield2_tilemap(*this, "playfield2"),
m_mob(*this, "mob"),
m_eof_data(*this, "eof"),
- m_scanline_int_timer(NULL),
- m_tilerow_update_timer(NULL),
- m_eof_timer(NULL),
+ m_scanline_int_timer(nullptr),
+ m_tilerow_update_timer(nullptr),
+ m_eof_timer(nullptr),
m_palette_bank(0),
m_pf0_xscroll_raw(0),
m_pf0_yscroll(0),
@@ -431,7 +431,7 @@ WRITE16_MEMBER(atari_vad_device::alpha_w)
WRITE16_MEMBER(atari_vad_device::playfield_upper_w)
{
m_playfield_tilemap->write_ext(space, offset, data, mem_mask);
- if (m_playfield2_tilemap != NULL)
+ if (m_playfield2_tilemap != nullptr)
m_playfield2_tilemap->write_ext(space, offset, data, mem_mask);
}
@@ -485,9 +485,9 @@ WRITE16_MEMBER(atari_vad_device::playfield2_latched_msb_w)
void atari_vad_device::device_start()
{
// verify configuration
- if (m_playfield_tilemap == NULL)
+ if (m_playfield_tilemap == nullptr)
throw emu_fatalerror("Playfield tilemap not found!");
- if (m_eof_data == NULL)
+ if (m_eof_data == nullptr)
throw emu_fatalerror("EOF data not found!");
// resolve callbacks
@@ -517,7 +517,7 @@ void atari_vad_device::device_start()
void atari_vad_device::device_reset()
{
// share extended memory between the two tilemaps
- if (m_playfield2_tilemap != NULL)
+ if (m_playfield2_tilemap != nullptr)
m_playfield2_tilemap->extmem().set(m_playfield_tilemap->extmem());
// reset the state
@@ -691,7 +691,7 @@ void atari_vad_device::internal_control_write(offs_t offset, UINT16 newword)
inline void atari_vad_device::update_pf_xscrolls()
{
m_playfield_tilemap->set_scrollx(0, m_pf0_xscroll_raw + ((m_pf1_xscroll_raw) & 7));
- if (m_playfield2_tilemap != NULL)
+ if (m_playfield2_tilemap != nullptr)
m_playfield2_tilemap->set_scrollx(0, m_pf1_xscroll_raw + 4);
}
@@ -708,7 +708,7 @@ void atari_vad_device::update_parameter(UINT16 newword)
{
case 9:
m_mo_xscroll = (newword >> 7) & 0x1ff;
- if (m_mob != NULL)
+ if (m_mob != nullptr)
m_mob->set_xscroll(m_mo_xscroll);
break;
@@ -724,13 +724,13 @@ void atari_vad_device::update_parameter(UINT16 newword)
case 13:
m_mo_yscroll = (newword >> 7) & 0x1ff;
- if (m_mob != NULL)
+ if (m_mob != nullptr)
m_mob->set_yscroll(m_mo_yscroll);
break;
case 14:
m_pf1_yscroll = (newword >> 7) & 0x1ff;
- if (m_playfield2_tilemap != NULL)
+ if (m_playfield2_tilemap != nullptr)
m_playfield2_tilemap->set_scrolly(0, m_pf1_yscroll);
break;
@@ -751,7 +751,7 @@ void atari_vad_device::update_parameter(UINT16 newword)
void atari_vad_device::update_tilerow(emu_timer &timer, int scanline)
{
// skip if out of bounds, or not enabled
- if (scanline <= m_screen->visible_area().max_y && (m_control[0x0a] & 0x2000) != 0 && m_alpha_tilemap != NULL)
+ if (scanline <= m_screen->visible_area().max_y && (m_control[0x0a] & 0x2000) != 0 && m_alpha_tilemap != nullptr)
{
// iterate over non-visible alpha tiles in this row
int offset = scanline / 8 * 64 + 48 + 2 * (scanline % 8);
@@ -960,7 +960,7 @@ atarigen_state::atarigen_state(const machine_config &mconfig, device_type type,
m_xscroll(*this, "xscroll"),
m_yscroll(*this, "yscroll"),
m_slapstic_num(0),
- m_slapstic(NULL),
+ m_slapstic(nullptr),
m_slapstic_bank(0),
m_slapstic_last_pc(0),
m_slapstic_last_address(0),
@@ -987,7 +987,7 @@ void atarigen_state::machine_start()
// allocate timers for all screens
screen_device_iterator iter(*this);
assert(iter.count() <= ARRAY_LENGTH(m_screen_timer));
- for (i = 0, screen = iter.first(); screen != NULL; i++, screen = iter.next())
+ for (i = 0, screen = iter.first(); screen != nullptr; i++, screen = iter.next())
{
m_screen_timer[i].screen = screen;
m_screen_timer[i].scanline_interrupt_timer = timer_alloc(TID_SCANLINE_INTERRUPT, (void *)screen);
@@ -1016,7 +1016,7 @@ void atarigen_state::machine_reset()
m_video_int_state = m_sound_int_state = m_scanline_int_state = 0;
// reset the control latch on the EAROM, if present
- if (m_earom != NULL)
+ if (m_earom != nullptr)
m_earom->set_control(0, 1, 1, 0, 0);
// reset the slapstic
@@ -1236,7 +1236,7 @@ void atarigen_state::slapstic_configure(cpu_device &device, offs_t base, offs_t
{
// reset in case we have no state
m_slapstic_num = chipnum;
- m_slapstic = NULL;
+ m_slapstic = nullptr;
// if we have a chip, install it
if (chipnum != 0)
@@ -1314,7 +1314,7 @@ READ16_MEMBER(atarigen_state::slapstic_r)
void atarigen_state::set_volume_by_type(int volume, device_type type)
{
sound_interface_iterator iter(*this);
- for (device_sound_interface *sound = iter.first(); sound != NULL; sound = iter.next())
+ for (device_sound_interface *sound = iter.first(); sound != nullptr; sound = iter.next())
if (sound->device().type() == type)
sound->set_output_gain(ALL_OUTPUTS, volume / 100.0);
}
@@ -1463,7 +1463,7 @@ void atarigen_state::blend_gfx(int gfx0, int gfx1, int mask0, int mask1)
gx0->set_granularity(granularity);
// free the second graphics element
- m_gfxdecode->set_gfx(gfx1, NULL);
+ m_gfxdecode->set_gfx(gfx1, nullptr);
}
diff --git a/src/mame/machine/awboard.cpp b/src/mame/machine/awboard.cpp
index be4b899ef95..342ff0b18e9 100644
--- a/src/mame/machine/awboard.cpp
+++ b/src/mame/machine/awboard.cpp
@@ -167,7 +167,7 @@ ADDRESS_MAP_END
aw_rom_board::aw_rom_board(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: naomi_g1_device(mconfig, AW_ROM_BOARD, "Sammy Atomiswave ROM Board", tag, owner, clock, "aw_rom_board", __FILE__)
{
- keyregion = 0;
+ keyregion = nullptr;
}
void aw_rom_board::static_set_keyregion(device_t &device, const char *_keyregion)
@@ -389,7 +389,7 @@ void aw_rom_board::dma_get_position(UINT8 *&base, UINT32 &limit, bool to_mainram
{
if(!to_mainram) {
limit = 0;
- base = 0;
+ base = nullptr;
return;
}
diff --git a/src/mame/machine/b2m.cpp b/src/mame/machine/b2m.cpp
index 2ff9f595aa1..10e9f587c21 100644
--- a/src/mame/machine/b2m.cpp
+++ b/src/mame/machine/b2m.cpp
@@ -183,7 +183,7 @@ WRITE8_MEMBER(b2m_state::b2m_ext_8255_portc_w)
UINT8 side = (data & 1) ^ 1;
static const char *names[] = { "fd0", "fd1"};
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
floppy_connector *con = machine().device<floppy_connector>(names[drive]);
if(con)
floppy = con->get_device();
diff --git a/src/mame/machine/balsente.cpp b/src/mame/machine/balsente.cpp
index 803b5dc5325..d9bde8cb7ae 100644
--- a/src/mame/machine/balsente.cpp
+++ b/src/mame/machine/balsente.cpp
@@ -843,7 +843,7 @@ void balsente_state::set_counter_0_ff(timer_device &timer, int newstate)
{
m_counter[0].count--;
if (m_counter[0].count == 0)
- balsente_counter_callback(timer, NULL, 0);
+ balsente_counter_callback(timer, nullptr, 0);
}
}
diff --git a/src/mame/machine/bbc.cpp b/src/mame/machine/bbc.cpp
index 1c181c96030..f30c170848b 100644
--- a/src/mame/machine/bbc.cpp
+++ b/src/mame/machine/bbc.cpp
@@ -1490,7 +1490,7 @@ WRITE_LINE_MEMBER(bbc_state::fdc_drq_w)
WRITE8_MEMBER(bbc_state::bbc_wd1770_status_w)
{
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
m_drive_control = data;
@@ -1531,7 +1531,7 @@ READ8_MEMBER(bbc_state::bbcm_wd177xl_read)
WRITE8_MEMBER(bbc_state::bbcm_wd1770l_write)
{
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
m_drive_control = data;
@@ -1554,7 +1554,7 @@ WRITE8_MEMBER(bbc_state::bbcm_wd1770l_write)
WRITE8_MEMBER(bbc_state::bbcm_wd1772l_write)
{
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
m_drive_control = data;
@@ -1601,7 +1601,7 @@ int bbc_state::bbc_load_rom(device_image_interface &image, generic_slot_device *
int bbc_state::bbcm_load_cart(device_image_interface &image, generic_slot_device *slot)
{
- if (image.software_entry() == NULL)
+ if (image.software_entry() == nullptr)
{
UINT32 filesize = image.length();
diff --git a/src/mame/machine/bebox.cpp b/src/mame/machine/bebox.cpp
index d5bceceb0aa..4b89b4b6871 100644
--- a/src/mame/machine/bebox.cpp
+++ b/src/mame/machine/bebox.cpp
@@ -270,8 +270,8 @@ void bebox_state::bebox_set_irq_bit(unsigned int interrupt_bit, int val)
{
static const char *const interrupt_names[32] =
{
- NULL,
- NULL,
+ nullptr,
+ nullptr,
"GEEKPORT",
"ADC",
"IR",
@@ -298,17 +298,17 @@ void bebox_state::bebox_set_irq_bit(unsigned int interrupt_bit, int val)
"COM3",
"COM2",
"COM1",
- NULL,
+ nullptr,
"SMI1",
"SMI0",
- NULL
+ nullptr
};
UINT32 old_interrupts;
if (LOG_INTERRUPTS)
{
/* make sure that we don't shoot ourself in the foot */
- assert_always((interrupt_bit < ARRAY_LENGTH(interrupt_names)) && (interrupt_names[interrupt_bit] != NULL), "Raising invalid interrupt");
+ assert_always((interrupt_bit < ARRAY_LENGTH(interrupt_names)) && (interrupt_names[interrupt_bit] != nullptr), "Raising invalid interrupt");
logerror("bebox_set_irq_bit(): pc[0]=0x%08x pc[1]=0x%08x %s interrupt #%u (%s)\n",
(unsigned) m_ppc1->pc(),
diff --git a/src/mame/machine/bublbobl.cpp b/src/mame/machine/bublbobl.cpp
index 84a3a6c125b..3998d02f2d6 100644
--- a/src/mame/machine/bublbobl.cpp
+++ b/src/mame/machine/bublbobl.cpp
@@ -25,7 +25,7 @@ WRITE8_MEMBER(bublbobl_state::bublbobl_bankswitch_w)
m_slave->set_input_line(INPUT_LINE_RESET, (data & 0x10) ? CLEAR_LINE : ASSERT_LINE);
/* bit 5 resets mcu */
- if (m_mcu != NULL) // only if we have a MCU
+ if (m_mcu != nullptr) // only if we have a MCU
m_mcu->set_input_line(INPUT_LINE_RESET, (data & 0x20) ? CLEAR_LINE : ASSERT_LINE);
/* bit 6 enables display */
diff --git a/src/mame/machine/c117.cpp b/src/mame/machine/c117.cpp
index de27ff06011..018fd21689b 100644
--- a/src/mame/machine/c117.cpp
+++ b/src/mame/machine/c117.cpp
@@ -38,8 +38,8 @@ namco_c117_device::namco_c117_device(const machine_config &mconfig, const char *
device_memory_interface(mconfig, *this),
m_subres_cb(*this),
m_program_config("program", ENDIANNESS_BIG, 8, 23),
- m_maincpu_tag(NULL),
- m_subcpu_tag(NULL)
+ m_maincpu_tag(nullptr),
+ m_subcpu_tag(nullptr)
{
}
diff --git a/src/mame/machine/c117.h b/src/mame/machine/c117.h
index ae5d8e4218b..99016721a54 100644
--- a/src/mame/machine/c117.h
+++ b/src/mame/machine/c117.h
@@ -50,7 +50,7 @@ protected:
virtual void device_reset();
// device_memory_interface overrides
- virtual const address_space_config *memory_space_config(address_spacenum spacenum = AS_0) const { return (spacenum == AS_PROGRAM) ? &m_program_config : NULL; }
+ virtual const address_space_config *memory_space_config(address_spacenum spacenum = AS_0) const { return (spacenum == AS_PROGRAM) ? &m_program_config : nullptr; }
private:
// internal helpers
diff --git a/src/mame/machine/coco.cpp b/src/mame/machine/coco.cpp
index f1177b8d9e8..ba88b004762 100644
--- a/src/mame/machine/coco.cpp
+++ b/src/mame/machine/coco.cpp
@@ -487,7 +487,7 @@ READ8_MEMBER( coco_state::pia1_pb_r )
|| (ram_size >= 0x8000 && (m_pia_0->b_output() & 0x40));
// serial in (PB0)
- bool serial_in = (m_rs232 != NULL) && (m_rs232->rxd_r() ? true : false);
+ bool serial_in = (m_rs232 != nullptr) && (m_rs232->rxd_r() ? true : false);
// composite the results
return (memory_sense ? 0x04 : 0x00)
@@ -728,7 +728,7 @@ void coco_state::update_sound(void)
coco_state::joystick_type_t coco_state::joystick_type(int index)
{
assert((index == 0) || (index == 1));
- return (m_joystick_type_control != NULL)
+ return (m_joystick_type_control != nullptr)
? (joystick_type_t) ((m_joystick_type_control->read() >> (index * 4)) & 0x0F)
: JOYSTICK_NONE;
}
@@ -741,7 +741,7 @@ coco_state::joystick_type_t coco_state::joystick_type(int index)
coco_state::hires_type_t coco_state::hires_interface_type(void)
{
- return (m_joystick_hires_control != NULL)
+ return (m_joystick_hires_control != nullptr)
? (hires_type_t) m_joystick_hires_control->read()
: HIRES_NONE;
}
@@ -984,7 +984,7 @@ void coco_state::update_prinout(bool prinout)
else
{
/* output bitbanger if present (only on CoCos) */
- if (m_rs232 != NULL)
+ if (m_rs232 != nullptr)
{
m_rs232->write_txd(prinout ? 1 : 0);
}
@@ -1122,7 +1122,7 @@ coco_vhd_image_device *coco_state::current_vhd(void)
{
case 0: return m_vhd_0;
case 1: return m_vhd_1;
- default: return NULL;
+ default: return nullptr;
}
}
@@ -1136,7 +1136,7 @@ READ8_MEMBER( coco_state::ff60_read )
{
UINT8 result;
- if ((current_vhd() != NULL) && (offset >= 32) && (offset <= 37))
+ if ((current_vhd() != nullptr) && (offset >= 32) && (offset <= 37))
{
result = current_vhd()->read(offset - 32);
}
@@ -1156,7 +1156,7 @@ READ8_MEMBER( coco_state::ff60_read )
WRITE8_MEMBER( coco_state::ff60_write )
{
- if ((current_vhd() != NULL) && (offset >= 32) && (offset <= 37))
+ if ((current_vhd() != nullptr) && (offset >= 32) && (offset <= 37))
{
current_vhd()->write(offset - 32, data);
}
@@ -1251,12 +1251,12 @@ static const char *const os9syscalls[] =
"F$SUser", /* Set User ID number */
"F$UnLoad", /* Unlink Module by name */
"F$Alarm", /* Color Computer Alarm Call (system wide) */
- NULL,
- NULL,
+ nullptr,
+ nullptr,
"F$NMLink", /* Color Computer NonMapping Link */
"F$NMLoad", /* Color Computer NonMapping Load */
- NULL,
- NULL,
+ nullptr,
+ nullptr,
"F$TPS", /* Return System's Ticks Per Second */
"F$TimAlm", /* COCO individual process alarm call */
"F$VIRQ", /* Install/Delete Virtual IRQ */
@@ -1304,50 +1304,50 @@ static const char *const os9syscalls[] =
"F$DelRAM", /* Deallocate RAM blocks */
"F$GCMDir", /* Pack module directory */
"F$AlHRam", /* Allocate HIGH RAM Blocks */
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
"F$RegDmp", /* Ron Lammardo's debugging register dump call */
"F$NVRAM", /* Non Volatile RAM (RTC battery backed static) read/write */
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
"I$Attach", /* Attach I/O Device */
"I$Detach", /* Detach I/O Device */
"I$Dup", /* Duplicate Path */
diff --git a/src/mame/machine/coco_vhd.h b/src/mame/machine/coco_vhd.h
index 3d4819cb8f5..4753d055646 100644
--- a/src/mame/machine/coco_vhd.h
+++ b/src/mame/machine/coco_vhd.h
@@ -36,9 +36,9 @@ public:
virtual bool is_creatable() const { return 1; }
virtual bool must_be_loaded() const { return 0; }
virtual bool is_reset_on_load() const { return 0; }
- virtual const char *image_interface() const { return NULL; }
+ virtual const char *image_interface() const { return nullptr; }
virtual const char *file_extensions() const { return "vhd"; }
- virtual const option_guide *create_option_guide() const { return NULL; }
+ virtual const option_guide *create_option_guide() const { return nullptr; }
// specific implementation
DECLARE_READ8_MEMBER(read) { return read(offset); }
diff --git a/src/mame/machine/cps2crpt.cpp b/src/mame/machine/cps2crpt.cpp
index d8d41771203..35bf3d11ef8 100644
--- a/src/mame/machine/cps2crpt.cpp
+++ b/src/mame/machine/cps2crpt.cpp
@@ -747,16 +747,16 @@ DRIVER_INIT_MEMBER(cps_state,cps2crpt)
UINT32 upper;
std::string skey1 = parameter("cryptkey1");;
- key[0] = strtoll(skey1.c_str(), 0, 16);
+ key[0] = strtoll(skey1.c_str(), nullptr, 16);
std::string skey2 = parameter("cryptkey2");
- key[1] = strtoll(skey2.c_str(), 0, 16);
+ key[1] = strtoll(skey2.c_str(), nullptr, 16);
std::string slower = parameter("cryptlower");
- lower = strtoll(slower.c_str(), 0, 16);
+ lower = strtoll(slower.c_str(), nullptr, 16);
std::string supper = parameter("cryptupper");
- upper = strtoll(supper.c_str(), 0, 16);
+ upper = strtoll(supper.c_str(), nullptr, 16);
// we have a proper key so use it to decrypt
if (lower!=0xff0000) // don't run the decrypt on 'dead key' games for now
diff --git a/src/mame/machine/cuda.cpp b/src/mame/machine/cuda.cpp
index 5c4964653b1..fc79fc6b32e 100644
--- a/src/mame/machine/cuda.cpp
+++ b/src/mame/machine/cuda.cpp
@@ -415,8 +415,8 @@ void cuda_device::device_start()
write_via_clock.resolve_safe();
write_via_data.resolve_safe();
- m_timer = timer_alloc(0, NULL);
- m_prog_timer = timer_alloc(1, NULL);
+ m_timer = timer_alloc(0, nullptr);
+ m_prog_timer = timer_alloc(1, nullptr);
save_item(NAME(ddrs[0]));
save_item(NAME(ddrs[1]));
save_item(NAME(ddrs[2]));
diff --git a/src/mame/machine/dc-ctrl.cpp b/src/mame/machine/dc-ctrl.cpp
index 44bd8847c87..f2b5531b64a 100644
--- a/src/mame/machine/dc-ctrl.cpp
+++ b/src/mame/machine/dc-ctrl.cpp
@@ -74,12 +74,12 @@ void dc_controller_device::fixed_status(UINT32 *dest)
{
dest[0] = 0x20000000; // Controller
dest[1] =
- ((port[2] != NULL) ? 0x010000 : 0) |
- ((port[3] != NULL) ? 0x020000 : 0) |
- ((port[4] != NULL) ? 0x040000 : 0) |
- ((port[5] != NULL) ? 0x080000 : 0) |
- ((port[6] != NULL) ? 0x100000 : 0) |
- ((port[7] != NULL) ? 0x200000 : 0) |
+ ((port[2] != nullptr) ? 0x010000 : 0) |
+ ((port[3] != nullptr) ? 0x020000 : 0) |
+ ((port[4] != nullptr) ? 0x040000 : 0) |
+ ((port[5] != nullptr) ? 0x080000 : 0) |
+ ((port[6] != nullptr) ? 0x100000 : 0) |
+ ((port[7] != nullptr) ? 0x200000 : 0) |
((port[0] ? port[0]->active() : 0) << 8) |
(port[1] ? port[1]->active() : 0); // 1st function - controller
dest[2] = 0; // No 2nd function
diff --git a/src/mame/machine/decocass_tape.cpp b/src/mame/machine/decocass_tape.cpp
index 74d777ab91d..48c9fd310ee 100644
--- a/src/mame/machine/decocass_tape.cpp
+++ b/src/mame/machine/decocass_tape.cpp
@@ -60,7 +60,7 @@ const device_type DECOCASS_TAPE = &device_creator<decocass_tape_device>;
decocass_tape_device::decocass_tape_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: device_t(mconfig, DECOCASS_TAPE, "DECO Cassette Tape", tag, owner, clock, "decocass_tape", __FILE__),
- m_tape_timer(NULL),
+ m_tape_timer(nullptr),
m_speed(0),
m_region(REGION_LEADER),
m_bitnum(0),
@@ -91,7 +91,7 @@ void decocass_tape_device::device_start()
/* fetch the data pointer */
m_tape_timer = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(decocass_tape_device::tape_clock_callback), this));
- if (region() == NULL)
+ if (region() == nullptr)
return;
UINT8 *regionbase = region()->base();
@@ -350,7 +350,7 @@ UINT8 decocass_tape_device::get_status_bits()
UINT8 decocass_tape_device::is_present()
{
- return region() != NULL;
+ return region() != nullptr;
}
diff --git a/src/mame/machine/dgn_beta.cpp b/src/mame/machine/dgn_beta.cpp
index 57de97d32f5..57b68c53879 100644
--- a/src/mame/machine/dgn_beta.cpp
+++ b/src/mame/machine/dgn_beta.cpp
@@ -104,23 +104,23 @@ struct bank_info_entry
static const struct bank_info_entry bank_info[] =
{
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b0_w),(dgn_beta_state*)0), 0x0000, 0x0fff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b1_w),(dgn_beta_state*)0), 0x1000, 0x1fff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b2_w),(dgn_beta_state*)0), 0x2000, 0x2fff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b3_w),(dgn_beta_state*)0), 0x3000, 0x3fff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b4_w),(dgn_beta_state*)0), 0x4000, 0x4fff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b5_w),(dgn_beta_state*)0), 0x5000, 0x5fff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b6_w),(dgn_beta_state*)0), 0x6000, 0x6fff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b7_w),(dgn_beta_state*)0), 0x7000, 0x7fff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b8_w),(dgn_beta_state*)0), 0x8000, 0x8fff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b9_w),(dgn_beta_state*)0), 0x9000, 0x9fff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bA_w),(dgn_beta_state*)0), 0xA000, 0xAfff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bB_w),(dgn_beta_state*)0), 0xB000, 0xBfff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bC_w),(dgn_beta_state*)0), 0xC000, 0xCfff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bD_w),(dgn_beta_state*)0), 0xD000, 0xDfff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bE_w),(dgn_beta_state*)0), 0xE000, 0xEfff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bF_w),(dgn_beta_state*)0), 0xF000, 0xFBff },
- { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bG_w),(dgn_beta_state*)0), 0xFF00, 0xFfff }
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b0_w),(dgn_beta_state*)nullptr), 0x0000, 0x0fff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b1_w),(dgn_beta_state*)nullptr), 0x1000, 0x1fff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b2_w),(dgn_beta_state*)nullptr), 0x2000, 0x2fff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b3_w),(dgn_beta_state*)nullptr), 0x3000, 0x3fff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b4_w),(dgn_beta_state*)nullptr), 0x4000, 0x4fff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b5_w),(dgn_beta_state*)nullptr), 0x5000, 0x5fff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b6_w),(dgn_beta_state*)nullptr), 0x6000, 0x6fff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b7_w),(dgn_beta_state*)nullptr), 0x7000, 0x7fff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b8_w),(dgn_beta_state*)nullptr), 0x8000, 0x8fff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_b9_w),(dgn_beta_state*)nullptr), 0x9000, 0x9fff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bA_w),(dgn_beta_state*)nullptr), 0xA000, 0xAfff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bB_w),(dgn_beta_state*)nullptr), 0xB000, 0xBfff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bC_w),(dgn_beta_state*)nullptr), 0xC000, 0xCfff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bD_w),(dgn_beta_state*)nullptr), 0xD000, 0xDfff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bE_w),(dgn_beta_state*)nullptr), 0xE000, 0xEfff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bF_w),(dgn_beta_state*)nullptr), 0xF000, 0xFBff },
+ { write8_delegate(FUNC(dgn_beta_state::dgnbeta_ram_bG_w),(dgn_beta_state*)nullptr), 0xFF00, 0xFfff }
};
#define is_last_page(page) (((page==LastPage) || (page==LastPage+1)) ? 1 : 0)
@@ -587,7 +587,7 @@ WRITE8_MEMBER(dgn_beta_state::d_pia1_pa_w)
}
/* Drive selects are binary encoded on PA0 & PA1 */
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
switch (~data & 0x03)
{
@@ -990,12 +990,12 @@ static const char *const os9syscalls[] =
"F$SUser", /* Set User ID number */
"F$UnLoad", /* Unlink Module by name */
"F$Alarm", /* Color Computer Alarm Call (system wide) */
- NULL,
- NULL,
+ nullptr,
+ nullptr,
"F$NMLink", /* Color Computer NonMapping Link */
"F$NMLoad", /* Color Computer NonMapping Load */
- NULL,
- NULL,
+ nullptr,
+ nullptr,
"F$TPS", /* Return System's Ticks Per Second */
"F$TimAlm", /* COCO individual process alarm call */
"F$VIRQ", /* Install/Delete Virtual IRQ */
@@ -1043,50 +1043,50 @@ static const char *const os9syscalls[] =
"F$DelRAM", /* Deallocate RAM blocks */
"F$GCMDir", /* Pack module directory */
"F$AlHRam", /* Allocate HIGH RAM Blocks */
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
"F$RegDmp", /* Ron Lammardo's debugging register dump call */
"F$NVRAM", /* Non Volatile RAM (RTC battery backed static) read/write */
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
- NULL,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
+ nullptr,
"I$Attach", /* Attach I/O Device */
"I$Detach", /* Detach I/O Device */
"I$Dup", /* Duplicate Path */
diff --git a/src/mame/machine/dgnalpha.cpp b/src/mame/machine/dgnalpha.cpp
index a146e1e3aae..20af8952b04 100644
--- a/src/mame/machine/dgnalpha.cpp
+++ b/src/mame/machine/dgnalpha.cpp
@@ -315,7 +315,7 @@ WRITE8_MEMBER( dragon_alpha_state::psg_porta_write )
/* Bit 4 is the motor on, in the real hardware these are inverted on their way to the drive */
/* Bits 5,6,7 are connected to /DDEN, ENP and 5/8 on the WD2797 */
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (BIT(data, 0)) floppy = m_floppy0->get_device();
if (BIT(data, 1)) floppy = m_floppy1->get_device();
diff --git a/src/mame/machine/egret.cpp b/src/mame/machine/egret.cpp
index 079a2504536..736cdfd3471 100644
--- a/src/mame/machine/egret.cpp
+++ b/src/mame/machine/egret.cpp
@@ -366,7 +366,7 @@ void egret_device::device_start()
write_via_clock.resolve_safe();
write_via_data.resolve_safe();
- m_timer = timer_alloc(0, NULL);
+ m_timer = timer_alloc(0, nullptr);
save_item(NAME(ddrs[0]));
save_item(NAME(ddrs[1]));
save_item(NAME(ddrs[2]));
diff --git a/src/mame/machine/electron.cpp b/src/mame/machine/electron.cpp
index 5ed4ca1e07a..3d92206ba3e 100644
--- a/src/mame/machine/electron.cpp
+++ b/src/mame/machine/electron.cpp
@@ -379,7 +379,7 @@ void electron_state::machine_start()
DEVICE_IMAGE_LOAD_MEMBER( electron_state, electron_cart )
{
- if (image.software_entry() == NULL)
+ if (image.software_entry() == nullptr)
{
UINT32 filesize = image.length();
diff --git a/src/mame/machine/fd1089.cpp b/src/mame/machine/fd1089.cpp
index 456192b32e6..5f8df8b0b3d 100644
--- a/src/mame/machine/fd1089.cpp
+++ b/src/mame/machine/fd1089.cpp
@@ -253,12 +253,12 @@ void fd1089_base_device::device_start()
// find the key
m_key = memregion("key")->base();
- if (m_key == NULL)
+ if (m_key == nullptr)
throw emu_fatalerror("FD1089 key region not found!");
// get a pointer to the ROM region
UINT16 *rombase = reinterpret_cast<UINT16 *>(region()->base());
- if (rombase == NULL)
+ if (rombase == nullptr)
throw emu_fatalerror("FD1089 found no ROM data to decrypt!");
// determine length and resize our internal buffers
diff --git a/src/mame/machine/fd1094.cpp b/src/mame/machine/fd1094.cpp
index ce1abbfad92..4d0992ef30e 100644
--- a/src/mame/machine/fd1094.cpp
+++ b/src/mame/machine/fd1094.cpp
@@ -558,9 +558,9 @@ fd1094_device::fd1094_device(const machine_config &mconfig, const char *tag, dev
m_state(0x00),
m_irqmode(false),
m_cache(*this),
- m_srcbase(NULL),
+ m_srcbase(nullptr),
m_srcbytes(0),
- m_key(NULL)
+ m_key(nullptr)
{
// override the name after the m68000 initializes
m_name.assign("FD1094");
@@ -637,11 +637,11 @@ void fd1094_device::device_start()
{
// find the key
m_key = memregion("key")->base();
- if (m_key == NULL)
+ if (m_key == nullptr)
throw emu_fatalerror("FD1094 key region not found!");
// get a pointer to the ROM region
- if (region() != NULL)
+ if (region() != nullptr)
{
m_srcbase = reinterpret_cast<UINT16 *>(region()->base());
m_srcbytes = region()->bytes();
@@ -651,7 +651,7 @@ void fd1094_device::device_start()
else
{
memory_share *share = owner()->memshare(tag());
- if (share != NULL)
+ if (share != nullptr)
{
m_srcbase = reinterpret_cast<UINT16 *>(share->ptr());
m_srcbytes = share->bytes();
@@ -659,7 +659,7 @@ void fd1094_device::device_start()
}
// if we got nothing, error
- if (m_srcbase == NULL)
+ if (m_srcbase == nullptr)
throw emu_fatalerror("FD1094 found no data to decrypt!");
// determine length and configure our cache
diff --git a/src/mame/machine/gaelco3d.cpp b/src/mame/machine/gaelco3d.cpp
index 4f576eba8fe..a8fe3f32590 100644
--- a/src/mame/machine/gaelco3d.cpp
+++ b/src/mame/machine/gaelco3d.cpp
@@ -192,11 +192,11 @@ gaelco_serial_device::gaelco_serial_device(const machine_config &mconfig, const
m_status(0),
m_last_in_msg_cnt(0),
m_slack_cnt(0),
- m_sync_timer(NULL),
- m_in_ptr(NULL),
- m_out_ptr(NULL),
- m_os_shmem(NULL),
- m_shmem(NULL)
+ m_sync_timer(nullptr),
+ m_in_ptr(nullptr),
+ m_out_ptr(nullptr),
+ m_os_shmem(nullptr),
+ m_shmem(nullptr)
{
}
@@ -221,7 +221,7 @@ void gaelco_serial_device::device_start()
#endif
m_os_shmem = osd_sharedmem_alloc(PATH_NAME, 0, sizeof(shmem_t));
- if (m_os_shmem == NULL)
+ if (m_os_shmem == nullptr)
{
m_os_shmem = osd_sharedmem_alloc(PATH_NAME, 1, sizeof(shmem_t));
m_shmem = (shmem_t *) osd_sharedmem_ptr(m_os_shmem);
diff --git a/src/mame/machine/gamecom.cpp b/src/mame/machine/gamecom.cpp
index 148a0585928..259443b728e 100644
--- a/src/mame/machine/gamecom.cpp
+++ b/src/mame/machine/gamecom.cpp
@@ -22,7 +22,7 @@ void gamecom_state::machine_reset()
m_bank3->set_base(rom);
m_bank4->set_base(rom);
- m_cart_ptr = NULL;
+ m_cart_ptr = nullptr;
m_lch_reg = 0x07;
m_lcv_reg = 0x27;
m_lcdc_reg = 0xb0;
@@ -179,7 +179,7 @@ WRITE8_MEMBER( gamecom_state::gamecom_pio_w )
{
case 0x40: m_cart_ptr = m_cart1_rom->base(); break;
case 0x80: m_cart_ptr = m_cart2_rom->base(); break;
- default: m_cart_ptr = NULL; break;
+ default: m_cart_ptr = nullptr; break;
}
return;
}
diff --git a/src/mame/machine/gdrom.cpp b/src/mame/machine/gdrom.cpp
index 2909cda71db..59a11e97cc2 100644
--- a/src/mame/machine/gdrom.cpp
+++ b/src/mame/machine/gdrom.cpp
@@ -167,7 +167,7 @@ void gdrom_device::ExecCommand()
m_cur_subblock = 0;
}
- if (m_cdda != NULL)
+ if (m_cdda != nullptr)
{
m_cdda->stop_audio();
}
@@ -205,7 +205,7 @@ void gdrom_device::ExecCommand()
length = 4;
}
- if (m_cdda != NULL)
+ if (m_cdda != nullptr)
{
m_cdda->stop_audio();
}
diff --git a/src/mame/machine/genpin.h b/src/mame/machine/genpin.h
index 6dededf3b4b..5b72d09ff53 100644
--- a/src/mame/machine/genpin.h
+++ b/src/mame/machine/genpin.h
@@ -30,7 +30,7 @@ const char *const genpin_sample_names[] =
"relay_release",
"solenoid_engage",
"solenoid_release",
- 0 /* end of array */
+ nullptr /* end of array */
};
MACHINE_CONFIG_EXTERN( genpin_audio );
diff --git a/src/mame/machine/harddriv.cpp b/src/mame/machine/harddriv.cpp
index e802f2bfe09..9f4a74f8948 100644
--- a/src/mame/machine/harddriv.cpp
+++ b/src/mame/machine/harddriv.cpp
@@ -57,8 +57,8 @@ void harddriv_state::device_reset()
m_slapstic_device->slapstic_reset();
/* halt several of the DSPs to start */
- if (m_adsp != NULL) m_adsp->set_input_line(INPUT_LINE_HALT, ASSERT_LINE);
- if (m_dsp32 != NULL) m_dsp32->set_input_line(INPUT_LINE_HALT, ASSERT_LINE);
+ if (m_adsp != nullptr) m_adsp->set_input_line(INPUT_LINE_HALT, ASSERT_LINE);
+ if (m_dsp32 != nullptr) m_dsp32->set_input_line(INPUT_LINE_HALT, ASSERT_LINE);
m_last_gsp_shiftreg = 0;
@@ -72,14 +72,14 @@ void harddriv_state::device_reset()
m_adsp_br = 0;
m_adsp_xflag = 0;
- if (m_ds3sdsp != NULL)
+ if (m_ds3sdsp != nullptr)
{
m_ds3sdsp->load_boot_data(m_ds3sdsp->region()->base(), m_ds3sdsp_pgm_memory);
m_ds3sdsp_timer_en = 0;
m_ds3sdsp_internal_timer->adjust(attotime::never);
}
- if (m_ds3xdsp != NULL)
+ if (m_ds3xdsp != nullptr)
{
m_ds3xdsp->load_boot_data(m_ds3xdsp->region()->base(), m_ds3xdsp_pgm_memory);
m_ds3xdsp_timer_en = 0;
@@ -173,7 +173,7 @@ READ16_MEMBER( harddriv_state::hd68k_msp_io_r )
UINT16 result;
offset = (offset / 2) ^ 1;
m_hd34010_host_access = TRUE;
- result = (m_msp != NULL) ? m_msp->host_r(space, offset, 0xffff) : 0xffff;
+ result = (m_msp != nullptr) ? m_msp->host_r(space, offset, 0xffff) : 0xffff;
m_hd34010_host_access = FALSE;
return result;
}
@@ -182,7 +182,7 @@ READ16_MEMBER( harddriv_state::hd68k_msp_io_r )
WRITE16_MEMBER( harddriv_state::hd68k_msp_io_w )
{
offset = (offset / 2) ^ 1;
- if (m_msp != NULL)
+ if (m_msp != nullptr)
{
m_hd34010_host_access = TRUE;
m_msp->host_w(space, offset, data, 0xffff);
@@ -302,7 +302,7 @@ READ16_MEMBER( harddriv_state::hd68k_adc12_r )
READ16_MEMBER( harddriv_state::hd68k_sound_reset_r )
{
- if (m_jsa != NULL)
+ if (m_jsa != nullptr)
m_jsa->reset();
return ~0;
}
@@ -404,12 +404,12 @@ WRITE16_MEMBER( harddriv_state::hd68k_nwr_w )
break;
case 6: /* /GSPRES */
logerror("Write to /GSPRES(%d)\n", data);
- if (m_gsp != NULL)
+ if (m_gsp != nullptr)
m_gsp->set_input_line(INPUT_LINE_RESET, data ? CLEAR_LINE : ASSERT_LINE);
break;
case 7: /* /MSPRES */
logerror("Write to /MSPRES(%d)\n", data);
- if (m_msp != NULL)
+ if (m_msp != nullptr)
m_msp->set_input_line(INPUT_LINE_RESET, data ? CLEAR_LINE : ASSERT_LINE);
break;
}
diff --git a/src/mame/machine/hec2hrp.cpp b/src/mame/machine/hec2hrp.cpp
index 55db5bdfe5f..6ed49982f7f 100644
--- a/src/mame/machine/hec2hrp.cpp
+++ b/src/mame/machine/hec2hrp.cpp
@@ -104,7 +104,7 @@ TIMER_CALLBACK_MEMBER(hec2hrp_state::Callback_CK)
WRITE8_MEMBER( hec2hrp_state::minidisc_control_w )
{
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (BIT(data, 6)) floppy = m_floppy0->get_device();
// bit 7 = drive 2?
diff --git a/src/mame/machine/hp48.cpp b/src/mame/machine/hp48.cpp
index 6c6ad253001..e9769f159c1 100644
--- a/src/mame/machine/hp48.cpp
+++ b/src/mame/machine/hp48.cpp
@@ -940,7 +940,7 @@ void hp48_port_image_device::hp48_unfill_port()
state->m_modules[m_module].off_mask = 0x00fff; /* 2 KB */
state->m_modules[m_module].read = read8_delegate();
state->m_modules[m_module].write = write8_delegate();
- state->m_modules[m_module].data = NULL;
+ state->m_modules[m_module].data = nullptr;
state->m_modules[m_module].isnop = 1;
state->m_port_size[m_port] = 0;
}
@@ -1035,12 +1035,12 @@ DRIVER_INIT_MEMBER(hp48_state,hp48)
m_modules[i].off_mask = 0x00fff; /* 2 KB */
m_modules[i].read = read8_delegate();
m_modules[i].write = write8_delegate();
- m_modules[i].data = NULL;
+ m_modules[i].data = nullptr;
m_modules[i].isnop = 0;
}
m_port_size[0] = 0;
m_port_size[1] = 0;
- m_rom = NULL;
+ m_rom = nullptr;
}
void hp48_state::machine_reset()
diff --git a/src/mame/machine/igs022.cpp b/src/mame/machine/igs022.cpp
index 360b333d52f..6a6e45b5c79 100644
--- a/src/mame/machine/igs022.cpp
+++ b/src/mame/machine/igs022.cpp
@@ -29,7 +29,7 @@ void igs022_device::device_start()
{
// Reset stuff
memset(m_kb_regs, 0, 0x100 * sizeof(UINT32));
- m_sharedprotram = 0;
+ m_sharedprotram = nullptr;
save_item(NAME(m_kb_regs));
}
diff --git a/src/mame/machine/igs028.cpp b/src/mame/machine/igs028.cpp
index 5836d946933..5e71c2bff64 100644
--- a/src/mame/machine/igs028.cpp
+++ b/src/mame/machine/igs028.cpp
@@ -26,7 +26,7 @@ void igs028_device::device_validity_check(validity_checker &valid) const
void igs028_device::device_start()
{
- m_sharedprotram = 0;
+ m_sharedprotram = nullptr;
}
diff --git a/src/mame/machine/inder_sb.cpp b/src/mame/machine/inder_sb.cpp
index 5b62cabb5c8..bad2b30d279 100644
--- a/src/mame/machine/inder_sb.cpp
+++ b/src/mame/machine/inder_sb.cpp
@@ -120,7 +120,7 @@ WRITE_LINE_MEMBER(inder_sb_device::z80ctc_ch3)
static const z80_daisy_config daisy_chain[] =
{
{ "ctc" },
- { NULL }
+ { nullptr }
};
diff --git a/src/mame/machine/isbc_215g.cpp b/src/mame/machine/isbc_215g.cpp
index 000c620d1a7..e49818ee4d6 100644
--- a/src/mame/machine/isbc_215g.cpp
+++ b/src/mame/machine/isbc_215g.cpp
@@ -358,7 +358,7 @@ static MACHINE_CONFIG_FRAGMENT( isbc_215g )
MCFG_HARDDISK_ADD("drive0")
MCFG_HARDDISK_ADD("drive1")
- MCFG_ISBX_SLOT_ADD("sbx1", 0, isbx_cards, NULL)
+ MCFG_ISBX_SLOT_ADD("sbx1", 0, isbx_cards, nullptr)
MCFG_ISBX_SLOT_MINTR0_CALLBACK(WRITELINE(isbc_215g_device, isbx_irq_00_w))
MCFG_ISBX_SLOT_MINTR1_CALLBACK(WRITELINE(isbc_215g_device, isbx_irq_01_w))
MCFG_ISBX_SLOT_ADD("sbx2", 0, isbx_cards, "fdc_218a")
@@ -387,11 +387,11 @@ void isbc_215g_device::device_reset()
if(m_hdd0->get_hard_disk_file())
m_geom[0] = hard_disk_get_info(m_hdd0->get_hard_disk_file());
else
- m_geom[0] = 0;
+ m_geom[0] = nullptr;
if(m_hdd1->get_hard_disk_file())
m_geom[1] = hard_disk_get_info(m_hdd1->get_hard_disk_file());
else
- m_geom[1] = 0;
+ m_geom[1] = nullptr;
m_reset = false;
m_fdctc = false;
diff --git a/src/mame/machine/iteagle_fpga.cpp b/src/mame/machine/iteagle_fpga.cpp
index c5e0ebaa7df..9fa7cef6da8 100644
--- a/src/mame/machine/iteagle_fpga.cpp
+++ b/src/mame/machine/iteagle_fpga.cpp
@@ -49,7 +49,7 @@ void iteagle_fpga_device::device_start()
// RAM defaults to base address 0x000e0000
bank_infos[2].adr = 0x000e0000 & (~(bank_infos[2].size - 1));
- m_timer = timer_alloc(0, NULL);
+ m_timer = timer_alloc(0, nullptr);
// virtpool nvram
memset(m_ram, 0, sizeof(m_ram));
@@ -599,10 +599,10 @@ ADDRESS_MAP_END
static MACHINE_CONFIG_FRAGMENT( iteagle_ide )
- MCFG_BUS_MASTER_IDE_CONTROLLER_ADD("ide", ata_devices, "hdd", NULL, true)
+ MCFG_BUS_MASTER_IDE_CONTROLLER_ADD("ide", ata_devices, "hdd", nullptr, true)
MCFG_ATA_INTERFACE_IRQ_HANDLER(WRITELINE(iteagle_ide_device, ide_interrupt))
MCFG_BUS_MASTER_IDE_CONTROLLER_SPACE(":maincpu", AS_PROGRAM)
- MCFG_BUS_MASTER_IDE_CONTROLLER_ADD("ide2", ata_devices, NULL, "cdrom", true)
+ MCFG_BUS_MASTER_IDE_CONTROLLER_ADD("ide2", ata_devices, nullptr, "cdrom", true)
MCFG_ATA_INTERFACE_IRQ_HANDLER(WRITELINE(iteagle_ide_device, ide2_interrupt))
MCFG_BUS_MASTER_IDE_CONTROLLER_SPACE(":maincpu", AS_PROGRAM)
MACHINE_CONFIG_END
diff --git a/src/mame/machine/kaneko_calc3.cpp b/src/mame/machine/kaneko_calc3.cpp
index e5e7a128561..10390dae679 100644
--- a/src/mame/machine/kaneko_calc3.cpp
+++ b/src/mame/machine/kaneko_calc3.cpp
@@ -1706,7 +1706,7 @@ void kaneko_calc3_device::mcu_run()
{
int length;
- length = decompress_table(commandtabl, 0, m_writeaddress_current-2);
+ length = decompress_table(commandtabl, nullptr, m_writeaddress_current-2);
if (length)
{
diff --git a/src/mame/machine/kaypro.cpp b/src/mame/machine/kaypro.cpp
index 9b9c3a7bab7..1d3cdad73bd 100644
--- a/src/mame/machine/kaypro.cpp
+++ b/src/mame/machine/kaypro.cpp
@@ -47,7 +47,7 @@ WRITE8_MEMBER( kaypro_state::kayproii_pio_system_w )
membank("bank3")->set_entry(BIT(data, 7));
m_is_motor_off = BIT(data, 6);
- m_floppy = NULL;
+ m_floppy = nullptr;
if (BIT(data, 0))
m_floppy = m_floppy0->get_device();
else
@@ -108,7 +108,7 @@ WRITE8_MEMBER( kaypro_state::kaypro2x_system_port_w )
membank("bank3")->set_entry(BIT(data, 7));
m_is_motor_off = !BIT(data, 4);
- m_floppy = NULL;
+ m_floppy = nullptr;
if (!BIT(data, 0))
m_floppy = m_floppy0->get_device();
else
diff --git a/src/mame/machine/kc.cpp b/src/mame/machine/kc.cpp
index ad707f9dbc6..1f8c0d95ed2 100644
--- a/src/mame/machine/kc.cpp
+++ b/src/mame/machine/kc.cpp
@@ -332,7 +332,7 @@ void kc_state::update_0x0c000()
{
address_space &space = m_maincpu->space( AS_PROGRAM );
- if ((m_pio_data[0] & (1<<7)) && memregion("basic")->base() != NULL)
+ if ((m_pio_data[0] & (1<<7)) && memregion("basic")->base() != nullptr)
{
/* BASIC takes next priority */
LOG(("BASIC rom 0x0c000\n"));
diff --git a/src/mame/machine/konppc.cpp b/src/mame/machine/konppc.cpp
index 76908e28411..93dbc89041b 100644
--- a/src/mame/machine/konppc.cpp
+++ b/src/mame/machine/konppc.cpp
@@ -37,7 +37,7 @@ void konppc_device::device_start()
dsp_shared_ram_bank[i] = 0;
dsp_state[i] = 0x80;
- texture_bank[i] = NULL;
+ texture_bank[i] = nullptr;
nwk_device_sel[i] = 0;
nwk_fifo_read_ptr[i] = 0;
@@ -143,7 +143,7 @@ WRITE32_MEMBER( konppc_device::cgboard_dsp_comm_w_ppc )
if (data & 0x80000000)
dsp_state[cgboard_id] |= 0x10;
- if (k033906 != NULL) /* zr107.c has no PCI and some games only have one PCI Bridge */
+ if (k033906 != nullptr) /* zr107.c has no PCI and some games only have one PCI Bridge */
k033906->set_reg((data & 0x20000000) ? 1 : 0);
if (data & 0x10000000)
@@ -236,7 +236,7 @@ void konppc_device::dsp_comm_sharc_w(address_space &space, int board, int offset
device->set_flag_input(1, ASSERT_LINE);
}
- if (texture_bank[board] != NULL)
+ if (texture_bank[board] != nullptr)
{
int offset = (data & 0x08) ? 1 : 0;
@@ -250,7 +250,7 @@ void konppc_device::dsp_comm_sharc_w(address_space &space, int board, int offset
{
if (offset == 1)
{
- if (texture_bank[board] != NULL)
+ if (texture_bank[board] != nullptr)
{
int offset = (data & 0x08) ? 1 : 0;
diff --git a/src/mame/machine/lynx.cpp b/src/mame/machine/lynx.cpp
index 14ebecf2bbf..179ac99a40f 100644
--- a/src/mame/machine/lynx.cpp
+++ b/src/mame/machine/lynx.cpp
@@ -2066,7 +2066,7 @@ DEVICE_IMAGE_LOAD_MEMBER( lynx_state, lynx_cart )
UINT32 size = m_cart->common_get_size("rom");
UINT16 gran = 0;
- if (image.software_entry() == NULL)
+ if (image.software_entry() == nullptr)
{
// check for lnx header
const char *filetype = image.filetype();
@@ -2099,7 +2099,7 @@ DEVICE_IMAGE_LOAD_MEMBER( lynx_state, lynx_cart )
m_cart->common_load_rom(m_cart->get_rom_base(), size, "rom");
// set-up granularity
- if (image.software_entry() == NULL)
+ if (image.software_entry() == nullptr)
{
const char *filetype = image.filetype();
if (!core_stricmp(filetype, "lnx")) // from header
@@ -2126,7 +2126,7 @@ DEVICE_IMAGE_LOAD_MEMBER( lynx_state, lynx_cart )
}
// set-up rotation from softlist
- if (image.software_entry() != NULL)
+ if (image.software_entry() != nullptr)
{
const char *rotate = image.get_feature("rotation");
m_rotate = 0;
diff --git a/src/mame/machine/mac.cpp b/src/mame/machine/mac.cpp
index 52e4a576808..2eb6cc9383c 100644
--- a/src/mame/machine/mac.cpp
+++ b/src/mame/machine/mac.cpp
@@ -1910,7 +1910,7 @@ void mac_state::machine_reset()
this->set_memory_overlay(1);
}
- if (m_overlay_timeout != (emu_timer *)NULL)
+ if (m_overlay_timeout != (emu_timer *)nullptr)
{
m_overlay_timeout->adjust(m_maincpu->cycles_to_attotime(8));
}
@@ -1919,7 +1919,7 @@ void mac_state::machine_reset()
this->m_screen_buffer = 1;
/* setup 'classic' sound */
- if (machine().device("custom") != NULL)
+ if (machine().device("custom") != nullptr)
{
machine().device<mac_sound_device>("custom")->set_sound_buffer(0);
}
@@ -2092,7 +2092,7 @@ void mac_state::mac_driver_init(model_t model)
}
else
{
- m_overlay_timeout = (emu_timer *)NULL;
+ m_overlay_timeout = (emu_timer *)nullptr;
}
/* setup keyboard */
@@ -2257,7 +2257,7 @@ TIMER_CALLBACK_MEMBER(mac_state::mac_scanline_tick)
{
int scanline;
- if (machine().device("custom") != NULL)
+ if (machine().device("custom") != nullptr)
{
machine().device<mac_sound_device>("custom")->sh_updatebuffer();
}
@@ -3138,7 +3138,7 @@ const char *lookup_trap(UINT16 opcode)
if (traps[i].trap == opcode)
return traps[i].name;
}
- return NULL;
+ return nullptr;
}
diff --git a/src/mame/machine/maple-dc.cpp b/src/mame/machine/maple-dc.cpp
index f866243f799..dcefe0fd84c 100644
--- a/src/mame/machine/maple-dc.cpp
+++ b/src/mame/machine/maple-dc.cpp
@@ -34,8 +34,8 @@ maple_dc_device::maple_dc_device(const machine_config &mconfig, const char *tag,
// Do not move that in device_start or there will be a race
// condition with the maple devices call to register_port.
memset(devices, 0, sizeof(devices));
- cpu = 0;
- irq_cb = 0;
+ cpu = nullptr;
+ irq_cb = nullptr;
}
void maple_dc_device::register_port(int port, maple_device *device)
diff --git a/src/mame/machine/mapledev.cpp b/src/mame/machine/mapledev.cpp
index 85906c33064..0f7630e3315 100644
--- a/src/mame/machine/mapledev.cpp
+++ b/src/mame/machine/mapledev.cpp
@@ -14,7 +14,7 @@ void maple_device::static_set_host(device_t &device, const char *_host_tag, int
maple_device::maple_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *source) : device_t(mconfig, type, name, tag, owner, clock, shortname, source)
{
- host_tag = 0;
+ host_tag = nullptr;
host_port = 0;
}
diff --git a/src/mame/machine/mbc55x.cpp b/src/mame/machine/mbc55x.cpp
index 5ef2d32a6ed..948f40e79bf 100644
--- a/src/mame/machine/mbc55x.cpp
+++ b/src/mame/machine/mbc55x.cpp
@@ -72,7 +72,7 @@ WRITE8_MEMBER( mbc55x_state::mbc55x_ppi_portb_w )
WRITE8_MEMBER( mbc55x_state::mbc55x_ppi_portc_w )
{
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
switch (data & 0x03)
{
@@ -374,7 +374,7 @@ static int instruction_hook(device_t &device, offs_t curpc)
addr_ptr = (UINT8*)space.get_read_ptr(curpc);
- if ((addr_ptr !=NULL) && (addr_ptr[0]==0xCD))
+ if ((addr_ptr !=nullptr) && (addr_ptr[0]==0xCD))
{
// logerror("int %02X called\n",addr_ptr[1]);
diff --git a/src/mame/machine/mbee.cpp b/src/mame/machine/mbee.cpp
index e2f6b08a94a..18dbba0126a 100644
--- a/src/mame/machine/mbee.cpp
+++ b/src/mame/machine/mbee.cpp
@@ -115,7 +115,7 @@ WRITE8_MEMBER( mbee_state::fdc_motor_w )
d2 side (1=side 1)
d1..d0 drive select (0 to 3) */
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
floppy = m_floppy0->get_device();
floppy->mon_w(0); // motor on always
floppy = m_floppy1->get_device();
diff --git a/src/mame/machine/mcr.cpp b/src/mame/machine/mcr.cpp
index b746ed79419..0332220fb50 100644
--- a/src/mame/machine/mcr.cpp
+++ b/src/mame/machine/mcr.cpp
@@ -78,7 +78,7 @@ const gfx_layout mcr_sprite_layout =
const z80_daisy_config mcr_daisy_chain[] =
{
{ "ctc" },
- { NULL }
+ { nullptr }
};
@@ -88,7 +88,7 @@ const z80_daisy_config mcr_ipu_daisy_chain[] =
{ "ipu_pio1" },
{ "ipu_sio" },
{ "ipu_pio0" },
- { NULL }
+ { nullptr }
};
diff --git a/src/mame/machine/megacdcd.cpp b/src/mame/machine/megacdcd.cpp
index 617d3615393..54c7d3c81a2 100644
--- a/src/mame/machine/megacdcd.cpp
+++ b/src/mame/machine/megacdcd.cpp
@@ -219,7 +219,7 @@ void lc89510_temp_device::CDD_GetPos(void)
CLEAR_CDD_RESULT
UINT32 msf;
CDD_STATUS &= 0xFF;
- if(segacd.cd == NULL) // no CD is there, bail out
+ if(segacd.cd == nullptr) // no CD is there, bail out
return;
CDD_STATUS |= SCD_STATUS;
msf = lba_to_msf_alt(SCD_CURLBA+150);
@@ -235,7 +235,7 @@ void lc89510_temp_device::CDD_GetTrackPos(void)
UINT32 msf;
CDD_STATUS &= 0xFF;
// UINT32 end_msf = ;
- if(segacd.cd == NULL) // no CD is there, bail out
+ if(segacd.cd == nullptr) // no CD is there, bail out
return;
CDD_STATUS |= SCD_STATUS;
elapsedlba = SCD_CURLBA - segacd.toc->tracks[ cdrom_get_track(segacd.cd, SCD_CURLBA) ].logframeofs;
@@ -250,7 +250,7 @@ void lc89510_temp_device::CDD_GetTrack(void)
{
CLEAR_CDD_RESULT
CDD_STATUS &= 0xFF;
- if(segacd.cd == NULL) // no CD is there, bail out
+ if(segacd.cd == nullptr) // no CD is there, bail out
return;
CDD_STATUS |= SCD_STATUS;
SCD_CURTRK = cdrom_get_track(segacd.cd, SCD_CURLBA)+1;
@@ -261,7 +261,7 @@ void lc89510_temp_device::CDD_Length(void)
{
CLEAR_CDD_RESULT
CDD_STATUS &= 0xFF;
- if(segacd.cd == NULL) // no CD is there, bail out
+ if(segacd.cd == nullptr) // no CD is there, bail out
return;
CDD_STATUS |= SCD_STATUS;
@@ -278,7 +278,7 @@ void lc89510_temp_device::CDD_FirstLast(void)
{
CLEAR_CDD_RESULT
CDD_STATUS &= 0xFF;
- if(segacd.cd == NULL) // no CD is there, bail out
+ if(segacd.cd == nullptr) // no CD is there, bail out
return;
CDD_STATUS |= SCD_STATUS;
CDD_MIN = 1; // first
@@ -293,7 +293,7 @@ void lc89510_temp_device::CDD_GetTrackAdr(void)
int last_track = cdrom_get_last_track(segacd.cd);
CDD_STATUS &= 0xFF;
- if(segacd.cd == NULL) // no CD is there, bail out
+ if(segacd.cd == nullptr) // no CD is there, bail out
return;
CDD_STATUS |= SCD_STATUS;
@@ -325,7 +325,7 @@ void lc89510_temp_device::CDD_GetTrackType(void)
int last_track = cdrom_get_last_track(segacd.cd);
CDD_STATUS &= 0xFF;
- if(segacd.cd == NULL) // no CD is there, bail out
+ if(segacd.cd == nullptr) // no CD is there, bail out
return;
CDD_STATUS |= SCD_STATUS;
@@ -361,7 +361,7 @@ void lc89510_temp_device::CDD_Play(running_machine &machine)
CLEAR_CDD_RESULT
UINT32 msf = getmsf_from_regs();
SCD_CURLBA = msf_to_lba(msf)-150;
- if(segacd.cd == NULL) // no CD is there, bail out
+ if(segacd.cd == nullptr) // no CD is there, bail out
return;
UINT32 end_msf = segacd.toc->tracks[ cdrom_get_track(segacd.cd, SCD_CURLBA) + 1 ].logframeofs;
SCD_CURTRK = cdrom_get_track(segacd.cd, SCD_CURLBA)+1;
@@ -386,7 +386,7 @@ void lc89510_temp_device::CDD_Seek(void)
CLEAR_CDD_RESULT
UINT32 msf = getmsf_from_regs();
SCD_CURLBA = msf_to_lba(msf)-150;
- if(segacd.cd == NULL) // no CD is there, bail out
+ if(segacd.cd == nullptr) // no CD is there, bail out
return;
SCD_CURTRK = cdrom_get_track(segacd.cd, SCD_CURLBA)+1;
LC8951UpdateHeader();
@@ -419,7 +419,7 @@ void lc89510_temp_device::CDD_Resume(running_machine &machine)
{
CLEAR_CDD_RESULT
STOP_CDC_READ
- if(segacd.cd == NULL) // no CD is there, bail out
+ if(segacd.cd == nullptr) // no CD is there, bail out
return;
SCD_CURTRK = cdrom_get_track(segacd.cd, SCD_CURLBA)+1;
SCD_STATUS = CDD_PLAYINGCDDA;
@@ -1156,16 +1156,16 @@ char* lc89510_temp_device::LC8915InitTransfer(int NeoCDDMACount)
{
if (!LC8951RegistersW[REG_W_DTTRG]) {
//bprintf(PRINT_ERROR, _T(" LC8951 DTTRG status invalid\n"));
- return NULL;
+ return nullptr;
}
if (!(LC8951RegistersW[REG_W_IFCTRL] & 0x02)) {
//bprintf(PRINT_ERROR, _T(" LC8951 DOUTEN status invalid\n"));
- return NULL;
+ return nullptr;
}
if (((LC8951RegistersW[REG_W_DACH] << 8) | LC8951RegistersW[REG_W_DACL]) + (NeoCDDMACount << 1) > LC89510_EXTERNAL_BUFFER_SIZE) {
//bprintf(PRINT_ERROR, _T(" DMA transfer exceeds current sector in LC8951 external buffer\n"));
- return NULL;
+ return nullptr;
}
char* addr = (char*)CDC_BUFFER + ((LC8951RegistersW[REG_W_DACH] << 8) | LC8951RegistersW[REG_W_DACL]);
diff --git a/src/mame/machine/mexico86.cpp b/src/mame/machine/mexico86.cpp
index c555928ee8e..dfffcf83b6a 100644
--- a/src/mame/machine/mexico86.cpp
+++ b/src/mame/machine/mexico86.cpp
@@ -18,7 +18,7 @@ WRITE8_MEMBER(mexico86_state::mexico86_f008_w)
{
m_audiocpu->set_input_line(INPUT_LINE_RESET, (data & 4) ? CLEAR_LINE : ASSERT_LINE);
- if (m_mcu != NULL)
+ if (m_mcu != nullptr)
{
// mexico 86, knight boy
m_mcu->set_input_line(INPUT_LINE_RESET, (data & 2) ? CLEAR_LINE : ASSERT_LINE);
diff --git a/src/mame/machine/mhavoc.cpp b/src/mame/machine/mhavoc.cpp
index 4c3a9dc2ab1..67453c09d87 100644
--- a/src/mame/machine/mhavoc.cpp
+++ b/src/mame/machine/mhavoc.cpp
@@ -84,7 +84,7 @@ void mhavoc_state::machine_start()
void mhavoc_state::machine_reset()
{
address_space &space = m_alpha->space(AS_PROGRAM);
- m_has_gamma_cpu = (m_gamma != NULL);
+ m_has_gamma_cpu = (m_gamma != nullptr);
membank("bank1")->configure_entry(0, m_zram0);
membank("bank1")->configure_entry(1, m_zram1);
diff --git a/src/mame/machine/microdrv.h b/src/mame/machine/microdrv.h
index 7d8913aae00..50225a3f564 100644
--- a/src/mame/machine/microdrv.h
+++ b/src/mame/machine/microdrv.h
@@ -61,7 +61,7 @@ public:
virtual bool is_reset_on_load() const { return 0; }
virtual const char *image_interface() const { return "ql_cass"; }
virtual const char *file_extensions() const { return "mdv"; }
- virtual const option_guide *create_option_guide() const { return NULL; }
+ virtual const option_guide *create_option_guide() const { return nullptr; }
// specific implementation
DECLARE_WRITE_LINE_MEMBER( clk_w );
diff --git a/src/mame/machine/micropolis.cpp b/src/mame/machine/micropolis.cpp
index 73b1b58178e..9cf03159e18 100644
--- a/src/mame/machine/micropolis.cpp
+++ b/src/mame/machine/micropolis.cpp
@@ -80,13 +80,13 @@ micropolis_device::micropolis_device(const machine_config &mconfig, const char *
m_data_offset(0),
m_data_count(0),
m_sector_length(0),
- m_drive(NULL)
+ m_drive(nullptr)
{
for (int i = 0; i < 6144; i++)
m_buffer[i] = 0;
for (int i = 0; i < 4; i++)
- m_floppy_drive_tags[i] = NULL;
+ m_floppy_drive_tags[i] = nullptr;
}
//-------------------------------------------------
diff --git a/src/mame/machine/microtan.cpp b/src/mame/machine/microtan.cpp
index 4fca3fe18ca..158c7a9fed5 100644
--- a/src/mame/machine/microtan.cpp
+++ b/src/mame/machine/microtan.cpp
@@ -463,11 +463,11 @@ DRIVER_INIT_MEMBER(microtan_state,microtan)
space.nop_readwrite(0x0400, 0xbbff);
break;
case 1: // +7K TANEX
- space.install_ram(0x0400, 0x1fff,NULL);
+ space.install_ram(0x0400, 0x1fff,nullptr);
space.nop_readwrite(0x2000, 0xbbff);
break;
default: // +7K TANEX + 40K TANRAM
- space.install_ram(0x0400, 0xbbff, NULL);
+ space.install_ram(0x0400, 0xbbff, nullptr);
break;
}
diff --git a/src/mame/machine/midwayic.cpp b/src/mame/machine/midwayic.cpp
index 3f77308544b..783eb12ed3e 100644
--- a/src/mame/machine/midwayic.cpp
+++ b/src/mame/machine/midwayic.cpp
@@ -225,7 +225,7 @@ midway_serial_pic2_device::midway_serial_pic2_device(const machine_config &mconf
m_time_index(0),
m_time_just_written(0),
m_yearoffs(0),
- m_time_write_timer(NULL)
+ m_time_write_timer(nullptr)
{
memset(m_buffer,0,sizeof(m_buffer));
memset(m_time_buf,0,sizeof(m_time_buf));
@@ -245,7 +245,7 @@ midway_serial_pic2_device::midway_serial_pic2_device(const machine_config &mconf
m_time_index(0),
m_time_just_written(0),
m_yearoffs(0),
- m_time_write_timer(NULL)
+ m_time_write_timer(nullptr)
{
memset(m_buffer,0,sizeof(m_buffer));
memset(m_time_buf,0,sizeof(m_time_buf));
@@ -595,11 +595,11 @@ midway_ioasic_device::midway_ioasic_device(const machine_config &mconfig, const
midway_serial_pic2_device(mconfig, MIDWAY_IOASIC, "Midway IOASIC", tag, owner, clock, "midway_ioasic", __FILE__),
m_has_dcs(0),
m_has_cage(0),
- m_dcs_cpu(NULL),
+ m_dcs_cpu(nullptr),
m_shuffle_type(0),
m_shuffle_default(0),
m_shuffle_active(0),
- m_shuffle_map(NULL),
+ m_shuffle_map(nullptr),
m_irq_callback(*this),
m_irq_state(0),
m_sound_irq_state(0),
@@ -609,8 +609,8 @@ midway_ioasic_device::midway_ioasic_device(const machine_config &mconfig, const
m_fifo_out(0),
m_fifo_bytes(0),
m_fifo_force_buffer_empty_pc(0),
- m_cage(NULL),
- m_dcs(NULL)
+ m_cage(nullptr),
+ m_dcs(nullptr)
{
memset(m_fifo,0,sizeof(m_fifo));
memset(m_reg,0,sizeof(m_reg));
@@ -641,14 +641,14 @@ void midway_ioasic_device::device_start()
/* do we have a DCS2 sound chip connected? (most likely) */
m_dcs = machine().device<dcs_audio_device>("dcs");
- m_has_dcs = (m_dcs != NULL);
+ m_has_dcs = (m_dcs != nullptr);
m_cage = machine().device<atari_cage_device>("cage");
- m_has_cage = (m_cage != NULL);
+ m_has_cage = (m_cage != nullptr);
m_dcs_cpu = m_dcs->subdevice("dcs2");
- if (m_dcs_cpu == NULL)
+ if (m_dcs_cpu == nullptr)
m_dcs_cpu = m_dcs->subdevice("dsio");
- if (m_dcs_cpu == NULL)
+ if (m_dcs_cpu == nullptr)
m_dcs_cpu = m_dcs->subdevice("denver");
m_shuffle_map = &shuffle_maps[m_shuffle_type][0];
// resolve callbacks
diff --git a/src/mame/machine/mie.cpp b/src/mame/machine/mie.cpp
index 108192fd021..55bac6f038f 100644
--- a/src/mame/machine/mie.cpp
+++ b/src/mame/machine/mie.cpp
@@ -96,9 +96,9 @@ mie_device::mie_device(const machine_config &mconfig, const char *tag, device_t
: maple_device(mconfig, MIE, "Sega 315-6146 MIE", tag, owner, clock, "mie", __FILE__)
{
memset(gpio_name, 0, sizeof(gpio_name));
- jvs_name = 0;
- cpu = 0;
- jvs = 0;
+ jvs_name = nullptr;
+ cpu = nullptr;
+ jvs = nullptr;
}
void mie_device::device_start()
@@ -110,7 +110,7 @@ void mie_device::device_start()
for (int i = 0; i < ARRAY_LENGTH(gpio_name); i++)
{
- gpio_port[i] = gpio_name[i] ? ioport(gpio_name[i]) : NULL;
+ gpio_port[i] = gpio_name[i] ? ioport(gpio_name[i]) : nullptr;
}
save_item(NAME(gpiodir));
diff --git a/src/mame/machine/mm1kb.cpp b/src/mame/machine/mm1kb.cpp
index 5097eb78225..88faf286961 100644
--- a/src/mame/machine/mm1kb.cpp
+++ b/src/mame/machine/mm1kb.cpp
@@ -45,7 +45,7 @@ static const char *const mm1_kb_sample_names[] =
"*MM1_keyboard",
"beep", // beep at 2.6 kHz
"power_switch", // not actually on the keyboard, but close enough :)
- 0
+ nullptr
};
bool mm1_keyboard_t::first_time = true;
diff --git a/src/mame/machine/model1.cpp b/src/mame/machine/model1.cpp
index 2b7460b2a8b..df1e8006bbf 100644
--- a/src/mame/machine/model1.cpp
+++ b/src/mame/machine/model1.cpp
@@ -1586,15 +1586,15 @@ const struct model1_state::function model1_state::ftab_vf[] = {
{ &model1_state::fsub, 2 },
{ &model1_state::fmul, 2 },
{ &model1_state::fdiv, 2 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::matrix_push, 0 },
{ &model1_state::matrix_pop, 0 },
{ &model1_state::matrix_write, 12 },
{ &model1_state::clear_stack, 0 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::anglev, 2 },
- { NULL, 0 },
- { NULL, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
{ &model1_state::track_select, 1 },
{ &model1_state::f14, 4 },
{ &model1_state::anglep, 4 },
@@ -1606,9 +1606,9 @@ const struct model1_state::function model1_state::ftab_vf[] = {
{ &model1_state::matrix_rotx, 1 },
{ &model1_state::matrix_roty, 1 },
{ &model1_state::matrix_rotz, 1 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::track_read_quad, 1 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::transform_point, 3 },
{ &model1_state::fsin_m1, 1 },
{ &model1_state::fcos_m1, 1 },
@@ -1616,10 +1616,10 @@ const struct model1_state::function model1_state::ftab_vf[] = {
{ &model1_state::fcosm_m1, 2 },
{ &model1_state::distance3, 6 },
- { NULL, 0 }, /* 0x20 */
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
+ { nullptr, 0 }, /* 0x20 */
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
{ &model1_state::acc_set, 1 },
{ &model1_state::acc_get, 0 },
{ &model1_state::acc_add, 1 },
@@ -1631,54 +1631,54 @@ const struct model1_state::function model1_state::ftab_vf[] = {
{ &model1_state::f44, 1 },
{ &model1_state::f45, 1 },
{ &model1_state::vlength, 3 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::track_read_info, 1 }, /* 0x30 */
{ &model1_state::colbox_set, 12 },
{ &model1_state::colbox_test, 3 },
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
{ &model1_state::track_lookup, 4 },
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
{ &model1_state::col_setcirc, 3 }, /* 0x40 */
{ &model1_state::col_testpt, 2 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::distance, 4 },
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
{ &model1_state::car_move, 4 },
{ &model1_state::cpa, 12 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::vmat_store, 1 },
{ &model1_state::vmat_restore, 1 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::vmat_mul, 2 },
{ &model1_state::vmat_read, 1 },
{ &model1_state::matrix_unrot, 0 },
{ &model1_state::f80, 0 }, /* 0x50 */
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::matrix_rtrans, 0 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::vmat_save, 1 },
{ &model1_state::vmat_load, 1 },
{ &model1_state::ram_setadr, 1 },
{ &model1_state::groundbox_test, 3 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::f89, 4 },
- { NULL, 0 },
- { NULL, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
{ &model1_state::f92, 4 },
{ &model1_state::f93, 1 },
{ &model1_state::f94, 1 },
@@ -1704,7 +1704,7 @@ const struct model1_state::function model1_state::ftab_swa[] = {
{ &model1_state::fsub, 2 },
{ &model1_state::fmul, 2 },
{ &model1_state::fdiv, 2 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::matrix_push, 0 },
{ &model1_state::matrix_pop, 0 },
{ &model1_state::matrix_write, 12 },
@@ -1724,9 +1724,9 @@ const struct model1_state::function model1_state::ftab_swa[] = {
{ &model1_state::matrix_rotx, 1 },
{ &model1_state::matrix_roty, 1 },
{ &model1_state::matrix_rotz, 1 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::f24_swa, 7 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::transform_point, 3 },
{ &model1_state::fsin_m1, 1 },
{ &model1_state::fcos_m1, 1 },
@@ -1734,8 +1734,8 @@ const struct model1_state::function model1_state::ftab_swa[] = {
{ &model1_state::fcosm_m1, 2 },
{ &model1_state::distance3, 6 },
- { NULL, 0 }, /* 0x20 */
- { NULL, 0 },
+ { nullptr, 0 }, /* 0x20 */
+ { nullptr, 0 },
{ &model1_state::ftoi, 1 },
{ &model1_state::itof, 1 },
{ &model1_state::acc_set, 1 },
@@ -1751,26 +1751,26 @@ const struct model1_state::function model1_state::ftab_swa[] = {
{ &model1_state::vlength, 3 },
{ &model1_state::f47, 3 },
- { NULL, 0 }, /* 0x30 */
+ { nullptr, 0 }, /* 0x30 */
{ &model1_state::f49_swa, 6 },
{ &model1_state::f50_swa, 4 },
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::f52, 0 },
{ &model1_state::matrix_rdir, 3 },
- { NULL, 0 },
- { NULL, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
{ &model1_state::f56, 7 },
{ &model1_state::f57, 0 },
{ &model1_state::matrix_readt, 0 },
{ &model1_state::acc_geti, 0 },
{ &model1_state::f60, 0 },
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
- { NULL, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
+ { nullptr, 0 },
{ &model1_state::push_and_ident, 0 }, /* 0x40 */
- { NULL, 0 },
+ { nullptr, 0 },
{ &model1_state::catmull_rom, 13 }
};
@@ -1792,7 +1792,7 @@ TGP_FUNCTION( model1_state::function_get_vf )
count += FIFO_SIZE;
logerror("TGP function called with sizeout = %d\n", count);
}
- if(ARRAY_LENGTH(ftab_vf) > f && NULL != ftab_vf[f].cb) {
+ if(ARRAY_LENGTH(ftab_vf) > f && nullptr != ftab_vf[f].cb) {
m_fifoin_cbcount = ftab_vf[f].count;
m_fifoin_cb = model1_state::ftab_vf[f].cb;
// logerror("TGP function %d request, %d parameters\n", f, m_fifoin_cbcount);
@@ -1815,7 +1815,7 @@ TGP_FUNCTION( model1_state::function_get_swa )
count += FIFO_SIZE;
logerror("TGP function called with sizeout = %d\n", count);
}
- if(ARRAY_LENGTH(ftab_swa) > f && NULL != ftab_swa[f].cb) {
+ if(ARRAY_LENGTH(ftab_swa) > f && nullptr != ftab_swa[f].cb) {
m_fifoin_cbcount = ftab_swa[f].count;
m_fifoin_cb = model1_state::ftab_swa[f].cb;
// logerror("TGP function %d request, %d parameters\n", f, m_fifoin_cbcount);
diff --git a/src/mame/machine/msx.cpp b/src/mame/machine/msx.cpp
index 92add704ebe..11402a50c40 100644
--- a/src/mame/machine/msx.cpp
+++ b/src/mame/machine/msx.cpp
@@ -407,7 +407,7 @@ void msx_state::msx_memory_init()
{
for ( int page = 0; page < 4; page++ )
{
- if ( m_all_slots[prim][sec][page] == NULL )
+ if ( m_all_slots[prim][sec][page] == nullptr )
{
m_all_slots[prim][sec][page] = &m_empty_slot;
}
diff --git a/src/mame/machine/mtx.cpp b/src/mame/machine/mtx.cpp
index 0594ec6c086..26a0ae6876a 100644
--- a/src/mame/machine/mtx.cpp
+++ b/src/mame/machine/mtx.cpp
@@ -347,7 +347,7 @@ SNAPSHOT_LOAD_MEMBER( mtx_state, mtx )
// verify first byte
if (header[0] != 0xff)
{
- image.seterror(IMAGE_ERROR_INVALIDIMAGE, NULL);
+ image.seterror(IMAGE_ERROR_INVALIDIMAGE, nullptr);
return IMAGE_INIT_FAIL;
}
diff --git a/src/mame/machine/n64.cpp b/src/mame/machine/n64.cpp
index e3270364f66..91ce7e482e4 100644
--- a/src/mame/machine/n64.cpp
+++ b/src/mame/machine/n64.cpp
@@ -23,7 +23,7 @@ const device_type N64PERIPH = &device_creator<n64_periphs>;
n64_periphs::n64_periphs(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: device_t(mconfig, N64PERIPH, "N64 Periphal Chips", tag, owner, clock, "n64_periphs", __FILE__)
, device_video_interface(mconfig, *this)
- , m_nvram_image(NULL)
+ , m_nvram_image(nullptr)
, dd_present(false)
, disk_present(false)
, cart_present(false)
@@ -1281,7 +1281,7 @@ n64_periphs::AUDIO_DMA *n64_periphs::ai_fifo_get_top()
}
else
{
- return NULL;
+ return nullptr;
}
}
@@ -1324,7 +1324,7 @@ void n64_periphs::ai_timer_tick()
signal_rcp_interrupt(AI_INTERRUPT);
// keep playing if there's another DMA queued
- if (ai_fifo_get_top() != NULL)
+ if (ai_fifo_get_top() != nullptr)
{
ai_dma();
}
@@ -2736,7 +2736,7 @@ void n64_state::n64_machine_stop()
{
n64_periphs *periphs = machine().device<n64_periphs>("rcp");
- if( periphs->m_nvram_image == NULL )
+ if( periphs->m_nvram_image == nullptr )
return;
device_image_interface *image = dynamic_cast<device_image_interface *>(periphs->m_nvram_image);
diff --git a/src/mame/machine/namco51.cpp b/src/mame/machine/namco51.cpp
index eb8e17cc02d..2cd77ab69b5 100644
--- a/src/mame/machine/namco51.cpp
+++ b/src/mame/machine/namco51.cpp
@@ -97,7 +97,7 @@ WRITE8_MEMBER( namco_51xx_device::write )
{
/* kludge for a possible bug in Xevious */
- static const game_driver *namcoio_51XX_driver = NULL;
+ static const game_driver *namcoio_51XX_driver = nullptr;
static int namcoio_51XX_kludge = 0;
/* Only compute namcoio_51XX_kludge when gamedrv changes */
diff --git a/src/mame/machine/namcos2.cpp b/src/mame/machine/namcos2.cpp
index 5561aac6300..7265a607d81 100644
--- a/src/mame/machine/namcos2.cpp
+++ b/src/mame/machine/namcos2.cpp
@@ -101,7 +101,7 @@ void namcos2_shared_state::reset_all_subcpus(int state)
MACHINE_START_MEMBER(namcos2_shared_state,namcos2)
{
- namcos2_kickstart = NULL;
+ namcos2_kickstart = nullptr;
m_eeprom = auto_alloc_array(machine(), UINT8, m_eeprom_size);
machine().device<nvram_device>("nvram")->set_base(m_eeprom, m_eeprom_size);
m_posirq_timer = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(namcos2_shared_state::namcos2_posirq_tick),this));
@@ -448,9 +448,9 @@ void namcos2_shared_state::init_c148()
UINT16 namcos2_shared_state::readwrite_c148( address_space &space, offs_t offset, UINT16 data, int bWrite )
{
offs_t addr = ((offset * 2) + 0x1c0000) & 0x1fe000;
- device_t *altcpu = NULL;
- UINT16 *pC148Reg = NULL;
- UINT16 *pC148RegAlt = NULL;
+ device_t *altcpu = nullptr;
+ UINT16 *pC148Reg = nullptr;
+ UINT16 *pC148RegAlt = nullptr;
UINT16 result = 0;
if (&space.device() == m_maincpu)
@@ -563,7 +563,7 @@ UINT16 namcos2_shared_state::readwrite_c148( address_space &space, offs_t offset
/* Suspend execution */
m_audiocpu->set_input_line(INPUT_LINE_RESET, ASSERT_LINE);
}
- if (namcos2_kickstart != NULL)
+ if (namcos2_kickstart != nullptr)
{
//printf( "dspkick=0x%x\n", data );
if (data & 0x04)
diff --git a/src/mame/machine/naomibd.cpp b/src/mame/machine/naomibd.cpp
index be95c340f96..704c357d70f 100644
--- a/src/mame/machine/naomibd.cpp
+++ b/src/mame/machine/naomibd.cpp
@@ -68,8 +68,8 @@ ADDRESS_MAP_END
naomi_board::naomi_board(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *source)
: naomi_g1_device(mconfig, type, name, tag, owner, clock, shortname, source)
{
- eeprom_tag = 0;
- rombdid_tag = 0;
+ eeprom_tag = nullptr;
+ rombdid_tag = nullptr;
}
void naomi_board::static_set_eeprom_tag(device_t &device, const char *_eeprom_tag, const char *_actel_tag)
@@ -94,7 +94,7 @@ void naomi_board::device_start()
if(eeprom_tag)
eeprom = machine().device<x76f100_device>(eeprom_tag);
else
- eeprom = 0;
+ eeprom = nullptr;
}
void naomi_board::device_reset()
@@ -110,7 +110,7 @@ void naomi_board::device_reset()
void naomi_board::dma_get_position(UINT8 *&base, UINT32 &limit, bool to_mainram)
{
if(!to_mainram) {
- base = 0;
+ base = nullptr;
limit = 0;
return;
}
diff --git a/src/mame/machine/naomigd.cpp b/src/mame/machine/naomigd.cpp
index fbe9cd3d32c..136d7a959b1 100644
--- a/src/mame/machine/naomigd.cpp
+++ b/src/mame/machine/naomigd.cpp
@@ -329,8 +329,8 @@ void naomi_gdrom_board::write_from_qword(UINT8 *region, UINT64 qword)
naomi_gdrom_board::naomi_gdrom_board(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: naomi_board(mconfig, NAOMI_GDROM_BOARD, "Sega NAOMI GDROM Board", tag, owner, clock, "naomi_gdrom_board", __FILE__)
{
- image_tag = 0;
- pic_tag = 0;
+ image_tag = nullptr;
+ pic_tag = nullptr;
}
void naomi_gdrom_board::static_set_tags(device_t &device, const char *_image_tag, const char *_pic_tag)
@@ -388,7 +388,7 @@ void naomi_gdrom_board::device_start()
{
naomi_board::device_start();
- dimm_data = 0;
+ dimm_data = nullptr;
dimm_data_size = 0;
char name[128];
diff --git a/src/mame/machine/naomim1.cpp b/src/mame/machine/naomim1.cpp
index 84d2db5ecef..5b16f278fb7 100644
--- a/src/mame/machine/naomim1.cpp
+++ b/src/mame/machine/naomim1.cpp
@@ -19,7 +19,7 @@ naomi_m1_board::naomi_m1_board(const machine_config &mconfig, const char *tag, d
READ16_MEMBER(naomi_m1_board::actel_id_r)
{
- if (rombdid_tag && memregion(rombdid_tag) != NULL)
+ if (rombdid_tag && memregion(rombdid_tag) != nullptr)
{
const UINT8 *bdid = memregion(rombdid_tag)->base();
return bdid[0] | (bdid[1] << 8);
@@ -34,7 +34,7 @@ void naomi_m1_board::device_start()
std::string skey = parameter("key");
if(!skey.empty())
- key = strtoll(skey.c_str(), 0, 16);
+ key = strtoll(skey.c_str(), nullptr, 16);
else
{
logerror("%s: Warning: key not provided\n", tag());
diff --git a/src/mame/machine/naomim4.cpp b/src/mame/machine/naomim4.cpp
index 2e23d76aca4..d22f7540ebc 100644
--- a/src/mame/machine/naomim4.cpp
+++ b/src/mame/machine/naomim4.cpp
@@ -49,7 +49,7 @@ ADDRESS_MAP_END
naomi_m4_board::naomi_m4_board(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: naomi_board(mconfig, NAOMI_M4_BOARD, "Sega NAOMI M4 Board", tag, owner, clock, "naomi_m4_board", __FILE__)
{
- key_tag = 0;
+ key_tag = nullptr;
}
void naomi_m4_board::static_set_tags(device_t &device, const char *_key_tag)
@@ -134,7 +134,7 @@ void naomi_m4_board::board_get_buffer(UINT8 *&base, UINT32 &limit)
if (cfi_mode) {
int fpr_num = 0;
- if (rombdid_tag && memregion(rombdid_tag) != NULL)
+ if (rombdid_tag && memregion(rombdid_tag) != nullptr)
{
fpr_num = *memregion(rombdid_tag)->base() & 0x7f;
@@ -217,7 +217,7 @@ READ16_MEMBER(naomi_m4_board::m4_id_r)
{
UINT16 epr_flag = 0;
- if (rombdid_tag && memregion(rombdid_tag) != NULL)
+ if (rombdid_tag && memregion(rombdid_tag) != nullptr)
{
epr_flag = *memregion(rombdid_tag)->base() & 0x80;
diff --git a/src/mame/machine/nb1414m4.cpp b/src/mame/machine/nb1414m4.cpp
index b860a3395cc..07fc537fd6c 100644
--- a/src/mame/machine/nb1414m4.cpp
+++ b/src/mame/machine/nb1414m4.cpp
@@ -35,7 +35,7 @@ const device_type NB1414M4 = &device_creator<nb1414m4_device>;
nb1414m4_device::nb1414m4_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: device_t(mconfig, NB1414M4, "NB1414M4 Mahjong Custom", tag, owner, clock, "nb1414m4", __FILE__),
device_video_interface(mconfig, *this),
- m_data(NULL)
+ m_data(nullptr)
{
}
diff --git a/src/mame/machine/ng_memcard.h b/src/mame/machine/ng_memcard.h
index 9d457ddaa59..f9dfd186c92 100644
--- a/src/mame/machine/ng_memcard.h
+++ b/src/mame/machine/ng_memcard.h
@@ -41,7 +41,7 @@ public:
virtual bool must_be_loaded() const { return false; }
virtual bool is_reset_on_load() const { return false; }
virtual const char *file_extensions() const { return "neo"; }
- virtual const option_guide *create_option_guide() const { return NULL; }
+ virtual const option_guide *create_option_guide() const { return nullptr; }
virtual bool call_load();
virtual void call_unload();
diff --git a/src/mame/machine/nmk112.cpp b/src/mame/machine/nmk112.cpp
index 6e925b53cc7..afe6588c000 100644
--- a/src/mame/machine/nmk112.cpp
+++ b/src/mame/machine/nmk112.cpp
@@ -22,10 +22,10 @@ const device_type NMK112 = &device_creator<nmk112_device>;
nmk112_device::nmk112_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: device_t(mconfig, NMK112, "NMK112", tag, owner, clock, "nmk112", __FILE__),
m_page_mask(0xff),
- m_tag0(NULL),
- m_tag1(NULL),
- m_rom0(NULL),
- m_rom1(NULL),
+ m_tag0(nullptr),
+ m_tag1(nullptr),
+ m_rom0(nullptr),
+ m_rom1(nullptr),
m_size0(0),
m_size1(0)
{
diff --git a/src/mame/machine/osborne1.cpp b/src/mame/machine/osborne1.cpp
index 5ba2a530edc..4d7856e8eb2 100644
--- a/src/mame/machine/osborne1.cpp
+++ b/src/mame/machine/osborne1.cpp
@@ -223,7 +223,7 @@ WRITE8_MEMBER( osborne1_state::video_pia_port_b_w )
}
else
{
- m_fdc->set_floppy(NULL);
+ m_fdc->set_floppy(nullptr);
}
}
diff --git a/src/mame/machine/pce220_ser.h b/src/mame/machine/pce220_ser.h
index ec52e5c0476..e1d48a02cb8 100644
--- a/src/mame/machine/pce220_ser.h
+++ b/src/mame/machine/pce220_ser.h
@@ -38,9 +38,9 @@ public:
virtual bool is_creatable() const { return 1; }
virtual bool must_be_loaded() const { return 0; }
virtual bool is_reset_on_load() const { return 0; }
- virtual const char *image_interface() const { return NULL; }
+ virtual const char *image_interface() const { return nullptr; }
virtual const char *file_extensions() const { return "txt,ihx"; }
- virtual const option_guide *create_option_guide() const { return NULL; }
+ virtual const option_guide *create_option_guide() const { return nullptr; }
// specific implementation
UINT8 in_xin(void) { return m_xin & 0x01; }
diff --git a/src/mame/machine/pk8020.cpp b/src/mame/machine/pk8020.cpp
index e065aac7fd7..ef70113fdcb 100644
--- a/src/mame/machine/pk8020.cpp
+++ b/src/mame/machine/pk8020.cpp
@@ -830,7 +830,7 @@ WRITE8_MEMBER(pk8020_state::pk8020_portc_w)
WRITE8_MEMBER(pk8020_state::pk8020_portb_w)
{
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
// Turn all motors off
if (m_floppy0->get_device()) m_floppy0->get_device()->mon_w(1);
diff --git a/src/mame/machine/playch10.cpp b/src/mame/machine/playch10.cpp
index 44d35252341..b9c6cf5d56a 100644
--- a/src/mame/machine/playch10.cpp
+++ b/src/mame/machine/playch10.cpp
@@ -47,12 +47,12 @@ void playch10_state::machine_start()
machine().device("ppu")->memory().space(AS_PROGRAM).install_readwrite_handler(0, 0x1fff, read8_delegate(FUNC(playch10_state::pc10_chr_r),this), write8_delegate(FUNC(playch10_state::pc10_chr_w),this));
machine().device("ppu")->memory().space(AS_PROGRAM).install_readwrite_handler(0x2000, 0x3eff, read8_delegate(FUNC(playch10_state::pc10_nt_r),this),write8_delegate(FUNC(playch10_state::pc10_nt_w),this));
- if (NULL != m_vram)
+ if (nullptr != m_vram)
set_videoram_bank(0, 8, 0, 8);
else pc10_set_videorom_bank(0, 8, 0, 8);
nvram_device *nvram = machine().device<nvram_device>("nvram");
- if (nvram != NULL)
+ if (nvram != nullptr)
nvram->set_base(memregion("cart" )->base() + 0x6000, 0x1000);
}
@@ -387,7 +387,7 @@ void playch10_state::set_videoram_bank( int first, int count, int bank, int size
DRIVER_INIT_MEMBER(playch10_state,playch10)
{
- m_vram = NULL;
+ m_vram = nullptr;
/* set the controller to default */
m_pc10_gun_controller = 0;
@@ -410,7 +410,7 @@ DRIVER_INIT_MEMBER(playch10_state,pc_gun)
DRIVER_INIT_CALL(playch10);
/* we have no vram, make sure switching games doesn't point to an old allocation */
- m_vram = NULL;
+ m_vram = nullptr;
/* set the control type */
m_pc10_gun_controller = 1;
@@ -567,7 +567,7 @@ DRIVER_INIT_MEMBER(playch10_state,pcaboard)
m_mirroring = PPU_MIRROR_VERT;
/* we have no vram, make sure switching games doesn't point to an old allocation */
- m_vram = NULL;
+ m_vram = nullptr;
}
/**********************************************************************************/
@@ -618,7 +618,7 @@ DRIVER_INIT_MEMBER(playch10_state,pccboard)
machine().device("cart")->memory().space(AS_PROGRAM).install_write_handler(0x6000, 0x6000, write8_delegate(FUNC(playch10_state::cboard_vrom_switch_w),this));
/* we have no vram, make sure switching games doesn't point to an old allocation */
- m_vram = NULL;
+ m_vram = nullptr;
/* common init */
DRIVER_INIT_CALL(playch10);
@@ -743,7 +743,7 @@ DRIVER_INIT_MEMBER(playch10_state,pceboard)
UINT8 *prg = memregion("cart")->base();
/* we have no vram, make sure switching games doesn't point to an old allocation */
- m_vram = NULL;
+ m_vram = nullptr;
/* We do manual banking, in case the code falls through */
/* Copy the initial banks */
@@ -771,7 +771,7 @@ DRIVER_INIT_MEMBER(playch10_state,pcfboard)
UINT32 len = memregion("cart")->bytes();
/* we have no vram, make sure switching games doesn't point to an old allocation */
- m_vram = NULL;
+ m_vram = nullptr;
/* We do manual banking, in case the code falls through */
/* Copy the initial banks */
@@ -793,7 +793,7 @@ DRIVER_INIT_MEMBER(playch10_state,pcfboard_2)
/* extra ram at $6000-$6fff */
machine().device("cart")->memory().space(AS_PROGRAM).install_ram(0x6000, 0x6fff);
- m_vram = NULL;
+ m_vram = nullptr;
/* common init */
DRIVER_INIT_CALL(pcfboard);
@@ -957,7 +957,7 @@ DRIVER_INIT_MEMBER(playch10_state,pcgboard)
{
ppu2c0x_device *ppu = machine().device<ppu2c0x_device>("ppu");
UINT8 *prg = memregion("cart")->base();
- m_vram = NULL;
+ m_vram = nullptr;
/* We do manual banking, in case the code falls through */
/* Copy the initial banks */
@@ -986,7 +986,7 @@ DRIVER_INIT_MEMBER(playch10_state,pcgboard)
DRIVER_INIT_MEMBER(playch10_state,pcgboard_type2)
{
- m_vram = NULL;
+ m_vram = nullptr;
/* common init */
DRIVER_INIT_CALL(pcgboard);
diff --git a/src/mame/machine/pmd85.cpp b/src/mame/machine/pmd85.cpp
index d5435443d26..df62cd75b69 100644
--- a/src/mame/machine/pmd85.cpp
+++ b/src/mame/machine/pmd85.cpp
@@ -402,7 +402,7 @@ WRITE8_MEMBER(pmd85_state::pmd85_ppi_2_portc_w)
READ8_MEMBER(pmd85_state::pmd85_ppi_3_porta_r)
{
- if (memregion("user1")->base() != NULL)
+ if (memregion("user1")->base() != nullptr)
return memregion("user1")->base()[m_ppi_port_outputs[3][1] | (m_ppi_port_outputs[3][2] << 8)];
else
return 0;
@@ -797,7 +797,7 @@ DRIVER_INIT_MEMBER(pmd85_state,mato)
}
for ( int i = 9; i < 16; i++ )
{
- m_io_port[i] = NULL;
+ m_io_port[i] = nullptr;
}
}
diff --git a/src/mame/machine/prof80mmu.cpp b/src/mame/machine/prof80mmu.cpp
index ebdccf33004..68bdabb7237 100644
--- a/src/mame/machine/prof80mmu.cpp
+++ b/src/mame/machine/prof80mmu.cpp
@@ -61,7 +61,7 @@ void prof80_mmu_device::device_start()
const address_space_config *prof80_mmu_device::memory_space_config(address_spacenum spacenum) const
{
- return (spacenum == AS_PROGRAM) ? &m_program_space_config : NULL;
+ return (spacenum == AS_PROGRAM) ? &m_program_space_config : nullptr;
}
diff --git a/src/mame/machine/psion_pack.cpp b/src/mame/machine/psion_pack.cpp
index d5ca2da2324..eef4bdc4709 100644
--- a/src/mame/machine/psion_pack.cpp
+++ b/src/mame/machine/psion_pack.cpp
@@ -128,7 +128,7 @@ void datapack_device::update()
if ((m_control & DP_LINE_OUTPUT_ENABLE) && !(m_control & DP_LINE_RESET))
{
// write data
- if (software_entry() == NULL && (m_id & DP_ID_WRITE))
+ if (software_entry() == nullptr && (m_id & DP_ID_WRITE))
{
fseek(pack_addr + OPK_HEAD_SIZE, SEEK_SET);
fwrite(&m_data, 1);
@@ -164,7 +164,7 @@ void datapack_device::update()
else if (!(m_control & DP_LINE_OUTPUT_ENABLE) && (m_control & DP_LINE_RESET))
{
// read datapack ID
- if ((m_id & DP_ID_EPROM) || software_entry() != NULL)
+ if ((m_id & DP_ID_EPROM) || software_entry() != nullptr)
m_data = m_id;
else
m_data = 0x01; // for identify RAM pack
@@ -282,7 +282,7 @@ bool datapack_device::call_create(int format_type, option_resolution *create_arg
{
static const UINT8 opk_head[6] = {'O', 'P', 'K', 0x00, 0x00, 0x00};
- if (create_args != NULL)
+ if (create_args != nullptr)
{
m_id = 0x40;
m_id |= (option_resolution_lookup_int(create_args, 'R')) ? 0x00 : 0x02;
diff --git a/src/mame/machine/psxcd.cpp b/src/mame/machine/psxcd.cpp
index 5ee9eaee9dd..552ad78b3e4 100644
--- a/src/mame/machine/psxcd.cpp
+++ b/src/mame/machine/psxcd.cpp
@@ -108,7 +108,7 @@ void psxcd_device::device_start()
m_sysclock = sysclk;
- res_queue = NULL;
+ res_queue = nullptr;
rdp = 0;
status=status_shellopen;
mode=0;
@@ -171,7 +171,7 @@ void psxcd_device::device_reset()
}
open = true;
if(m_cdrom_handle)
- add_system_event(event_change_disk, m_sysclock, NULL);
+ add_system_event(event_change_disk, m_sysclock, nullptr);
while(res_queue)
{
@@ -188,7 +188,7 @@ void psxcd_device::device_reset()
m_cursec = 0;
m_mute = false;
m_dmaload = false;
- m_int1 = NULL;
+ m_int1 = nullptr;
curpos.w = 0;
}
@@ -197,7 +197,7 @@ bool psxcd_device::call_load()
bool ret = cdrom_image_device::call_load();
open = true;
if(ret == IMAGE_INIT_PASS)
- add_system_event(event_change_disk, m_sysclock, NULL); // 1 sec to spin up the disk
+ add_system_event(event_change_disk, m_sysclock, nullptr); // 1 sec to spin up the disk
return ret;
}
@@ -361,7 +361,7 @@ WRITE8_MEMBER( psxcd_device::write )
{
command_result *res = res_queue;
if(res == m_int1)
- m_int1 = NULL;
+ m_int1 = nullptr;
res_queue = res->next;
global_free(res);
@@ -508,7 +508,7 @@ void psxcd_device::cdcmd_readn()
start_read();
} else
{
- send_result(intr_diskerror, NULL, 0, 0x80);
+ send_result(intr_diskerror, nullptr, 0, 0x80);
}
}
@@ -671,7 +671,7 @@ void psxcd_device::cdcmd_gettn()
}
else
{
- send_result(intr_diskerror, NULL, 0, 0x80);
+ send_result(intr_diskerror, nullptr, 0, 0x80);
}
}
@@ -700,7 +700,7 @@ void psxcd_device::cdcmd_gettd()
}
else
{
- send_result(intr_diskerror, NULL, 0, 0x80);
+ send_result(intr_diskerror, nullptr, 0, 0x80);
}
}
@@ -744,7 +744,7 @@ void psxcd_device::cdcmd_test()
default:
verboselog(*this, 0, "psxcd: unimplemented test cmd %02x\n", cmdbuf[0]);
- cmd_complete(prepare_result(intr_diskerror, NULL, 0, 0x10));
+ cmd_complete(prepare_result(intr_diskerror, nullptr, 0, 0x10));
break;
}
}
@@ -779,7 +779,7 @@ void psxcd_device::cdcmd_id()
}
else
{
- send_result(intr_diskerror, NULL, 0, 0x80);
+ send_result(intr_diskerror, nullptr, 0, 0x80);
}
}
@@ -795,7 +795,7 @@ void psxcd_device::cdcmd_reads()
start_read();
} else
{
- send_result(intr_diskerror, NULL, 0, 0x80);
+ send_result(intr_diskerror, nullptr, 0, 0x80);
}
}
@@ -809,7 +809,7 @@ void psxcd_device::cdcmd_readtoc()
verboselog(*this, 1, "psxcd: readtoc\n");
send_result(intr_complete);
- send_result(intr_acknowledge, NULL, 0, default_irq_delay*3); // ?
+ send_result(intr_acknowledge, nullptr, 0, default_irq_delay*3); // ?
}
void psxcd_device::cdcmd_unknown12()
@@ -819,7 +819,7 @@ void psxcd_device::cdcmd_unknown12()
if(cmdbuf[0] == 1)
send_result(intr_complete);
else
- send_result(intr_diskerror, NULL, 0, 0x40);
+ send_result(intr_diskerror, nullptr, 0, 0x40);
}
void psxcd_device::cdcmd_illegal17()
@@ -841,7 +841,7 @@ void psxcd_device::illegalcmd(UINT8 cmd)
{
verboselog(*this, 0, "psxcd: unimplemented cd command %02x\n", cmd);
- send_result(intr_diskerror, NULL, 0, 0x40);
+ send_result(intr_diskerror, nullptr, 0, 0x40);
}
void psxcd_device::cmd_complete(command_result *res)
@@ -863,12 +863,12 @@ void psxcd_device::cmd_complete(command_result *res)
m_irq_handler(1);
m_regs.sr |= 0x20;
}
- res->next = NULL;
+ res->next = nullptr;
}
psxcd_device::command_result *psxcd_device::prepare_result(UINT8 res, UINT8 *data, int sz, UINT8 errcode)
{
- command_result *cr=global_alloc(command_result);
+ auto cr=global_alloc(command_result);
cr->res=res;
if (sz)
@@ -1008,7 +1008,7 @@ void psxcd_device::read_sector()
next_sector_t+=cyc;
- next_read_event = add_system_event(event_read_sector, cyc, NULL);
+ next_read_event = add_system_event(event_read_sector, cyc, nullptr);
} else
{
verboselog(*this, 1, "psxcd: autopause xa\n");
@@ -1073,7 +1073,7 @@ void psxcd_device::play_sector()
if ((mode&mode_report) && !(sector & 15)) // slow the int rate
{
- command_result *res=global_alloc(command_result);
+ auto res=global_alloc(command_result);
UINT8 track = cdrom_get_track(m_cdrom_handle, sector) + 1;
res->res=intr_dataready;
@@ -1105,7 +1105,7 @@ void psxcd_device::play_sector()
next_sector_t+=cyc>>1;
- next_read_event = add_system_event(event_play_sector, next_sector_t - m_maincpu->total_cycles(), NULL);
+ next_read_event = add_system_event(event_play_sector, next_sector_t - m_maincpu->total_cycles(), nullptr);
}
}
@@ -1118,7 +1118,7 @@ void psxcd_device::start_read()
if(!(mode & mode_cdda) && (cdrom_get_track_type(m_cdrom_handle, cdrom_get_track(m_cdrom_handle, sector + 150)) == CD_TRACK_AUDIO))
{
stop_read();
- cmd_complete(prepare_result(intr_diskerror, NULL, 0, 0x40));
+ cmd_complete(prepare_result(intr_diskerror, nullptr, 0, 0x40));
return;
}
send_result(intr_complete);
@@ -1134,7 +1134,7 @@ void psxcd_device::start_read()
systime+=start_read_delay;
next_sector_t=systime+cyc;
- next_read_event = add_system_event(event_read_sector, start_read_delay+preread_delay, NULL);
+ next_read_event = add_system_event(event_read_sector, start_read_delay+preread_delay, nullptr);
}
void psxcd_device::start_play()
@@ -1160,7 +1160,7 @@ void psxcd_device::start_play()
next_sector_t+=cyc>>1;
- next_read_event = add_system_event(event_play_sector, next_sector_t - m_maincpu->total_cycles(), NULL);
+ next_read_event = add_system_event(event_play_sector, next_sector_t - m_maincpu->total_cycles(), nullptr);
}
void psxcd_device::stop_read()
diff --git a/src/mame/machine/psxcd.h b/src/mame/machine/psxcd.h
index be11fbdbdd6..2d9a24e7310 100644
--- a/src/mame/machine/psxcd.h
+++ b/src/mame/machine/psxcd.h
@@ -90,8 +90,8 @@ private:
void illegalcmd(UINT8 cmd);
void cmd_complete(command_result *res);
- void send_result(UINT8 res, UINT8 *data=NULL, int sz=0, int delay=default_irq_delay, UINT8 errcode = 0);
- command_result *prepare_result(UINT8 res, UINT8 *data=NULL, int sz=0, UINT8 errcode = 0);
+ void send_result(UINT8 res, UINT8 *data=nullptr, int sz=0, int delay=default_irq_delay, UINT8 errcode = 0);
+ command_result *prepare_result(UINT8 res, UINT8 *data=nullptr, int sz=0, UINT8 errcode = 0);
void start_read();
void start_play();
diff --git a/src/mame/machine/rm380z.cpp b/src/mame/machine/rm380z.cpp
index 082dbf6ff75..68636e54262 100644
--- a/src/mame/machine/rm380z.cpp
+++ b/src/mame/machine/rm380z.cpp
@@ -210,7 +210,7 @@ WRITE8_MEMBER( rm380z_state::keyboard_put )
WRITE8_MEMBER( rm380z_state::disk_0_control )
{
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (BIT(data, 0)) floppy = m_floppy0->get_device();
if (BIT(data, 1)) floppy = m_floppy1->get_device();
diff --git a/src/mame/machine/rmnimbus.cpp b/src/mame/machine/rmnimbus.cpp
index ef41cc828ec..e2a5e3a2738 100644
--- a/src/mame/machine/rmnimbus.cpp
+++ b/src/mame/machine/rmnimbus.cpp
@@ -266,7 +266,7 @@ static int instruction_hook(device_t &device, offs_t curpc)
addr_ptr = (UINT8*)space.get_read_ptr(curpc);
- if ((addr_ptr !=NULL) && (addr_ptr[0]==0xCD))
+ if ((addr_ptr !=nullptr) && (addr_ptr[0]==0xCD))
{
if(DEBUG_SET_STATE(DECODE_BIOS) && (addr_ptr[1]==0xF0))
{
@@ -293,7 +293,7 @@ static void decode_subbios(device_t *device,offs_t pc, UINT8 raw_flag)
char drv_str[80];
char func_str[80];
- void (*dump_dssi)(device_t *,UINT16, UINT16 ,UINT8) = NULL;
+ void (*dump_dssi)(device_t *,UINT16, UINT16 ,UINT8) = nullptr;
device_t *cpu = device->machine().device(MAINCPU_TAG);
@@ -614,14 +614,14 @@ static void decode_subbios(device_t *device,offs_t pc, UINT8 raw_flag)
if(raw_flag)
{
- if(dump_dssi!=NULL)
+ if(dump_dssi!=nullptr)
dump_dssi(device,ds,si,raw_flag);
}
else
{
device->logerror("Type=%s, Driver=%s, Function=%s\n",type_str,drv_str,func_str);
- if(dump_dssi!=NULL)
+ if(dump_dssi!=nullptr)
dump_dssi(device,ds,si,raw_flag);
device->logerror("=======================================================================\n");
}
@@ -937,8 +937,8 @@ void rmnimbus_state::nimbus_bank_memory()
}
map_blocks[0] = ram;
- map_blocks[1] = (ramblocks[ramblock][1].blocksize==0) ? NULL : &ram[ramblocks[ramblock][1].blockbase*1024];
- map_blocks[2] = (ramblocks[ramblock][2].blocksize==0) ? NULL : &ram[ramblocks[ramblock][2].blockbase*1024];
+ map_blocks[1] = (ramblocks[ramblock][1].blocksize==0) ? nullptr : &ram[ramblocks[ramblock][1].blockbase*1024];
+ map_blocks[2] = (ramblocks[ramblock][2].blocksize==0) ? nullptr : &ram[ramblocks[ramblock][2].blockbase*1024];
//if(LOG_RAM) logerror("\n\nmcu_reg080=%02X, ramblock=%d, map_blocks[0]=%X, map_blocks[1]=%X, map_blocks[2]=%X\n",m_mcu_reg080,ramblock,(int)map_blocks[0],(int)map_blocks[1],(int)map_blocks[2]);
@@ -960,7 +960,7 @@ void rmnimbus_state::nimbus_bank_memory()
if(LOG_RAM) logerror("mapped %s",bank);
if((map_blockno>-1) && (block_ofs < ramblocks[ramblock][map_blockno].blocksize) &&
- (map_blocks[map_blockno]!=NULL))
+ (map_blocks[map_blockno]!=nullptr))
{
map_base=(ramsel==0x07) ? map_blocks[map_blockno] : &map_blocks[map_blockno][block_ofs*1024];
diff --git a/src/mame/machine/rx01.cpp b/src/mame/machine/rx01.cpp
index e916be7a1fb..c1889eb6a8b 100644
--- a/src/mame/machine/rx01.cpp
+++ b/src/mame/machine/rx01.cpp
@@ -17,7 +17,7 @@
#include "formats/basicdsk.h"
static LEGACY_FLOPPY_OPTIONS_START( rx01 )
- LEGACY_FLOPPY_OPTION(rx01, "img", "RX01 image", basicdsk_identify_default, basicdsk_construct_default, NULL,
+ LEGACY_FLOPPY_OPTION(rx01, "img", "RX01 image", basicdsk_identify_default, basicdsk_construct_default, nullptr,
HEADS([1])
TRACKS([77])
SECTORS([26])
diff --git a/src/mame/machine/samcoupe.cpp b/src/mame/machine/samcoupe.cpp
index 682d81d906c..15e814c659e 100644
--- a/src/mame/machine/samcoupe.cpp
+++ b/src/mame/machine/samcoupe.cpp
@@ -87,7 +87,7 @@ void samcoupe_state::samcoupe_update_bank(address_space &space, int bank_num, UI
if (!is_readonly)
sam_bank_write_ptr[bank_num-1] = memory;
else
- sam_bank_write_ptr[bank_num-1] = NULL;
+ sam_bank_write_ptr[bank_num-1] = nullptr;
// installing banks on the fly is too slow (20% speed in Manic Miner gameplay vs 300% speed)
#if 0
@@ -117,7 +117,7 @@ void samcoupe_state::samcoupe_install_ext_mem(address_space &space)
if (m_lext >> 6 < m_ram->size() >> 20)
mem = &m_ram->pointer()[(m_ram->size() & 0xfffff) + (m_lext >> 6) * 0x100000 + (m_lext & 0x3f) * 0x4000];
else
- mem = NULL;
+ mem = nullptr;
samcoupe_update_bank(space, 3, mem, FALSE);
@@ -125,7 +125,7 @@ void samcoupe_state::samcoupe_install_ext_mem(address_space &space)
if (m_hext >> 6 < m_ram->size() >> 20)
mem = &m_ram->pointer()[(m_ram->size() & 0xfffff) + (m_hext >> 6) * 0x100000 + (m_hext & 0x3f) * 0x4000];
else
- mem = NULL;
+ mem = nullptr;
samcoupe_update_bank(space, 4, mem, FALSE);
}
@@ -144,7 +144,7 @@ void samcoupe_state::samcoupe_update_memory(address_space &space)
if ((m_lmpr & 0x1F) <= PAGE_MASK)
memory = &m_ram->pointer()[(m_lmpr & PAGE_MASK) * 0x4000];
else
- memory = NULL; /* Attempt to page in non existant ram region */
+ memory = nullptr; /* Attempt to page in non existant ram region */
is_readonly = FALSE;
}
else
@@ -159,7 +159,7 @@ void samcoupe_state::samcoupe_update_memory(address_space &space)
if (((m_lmpr + 1) & 0x1f) <= PAGE_MASK)
memory = &m_ram->pointer()[((m_lmpr + 1) & PAGE_MASK) * 0x4000];
else
- memory = NULL; /* Attempt to page in non existant ram region */
+ memory = nullptr; /* Attempt to page in non existant ram region */
samcoupe_update_bank(space, 2, memory, FALSE);
/* only update bank 3 and 4 when external memory is not enabled */
@@ -173,7 +173,7 @@ void samcoupe_state::samcoupe_update_memory(address_space &space)
if ((m_hmpr & 0x1F) <= PAGE_MASK )
memory = &m_ram->pointer()[(m_hmpr & PAGE_MASK)*0x4000];
else
- memory = NULL; /* Attempt to page in non existant ram region */
+ memory = nullptr; /* Attempt to page in non existant ram region */
samcoupe_update_bank(space, 3, memory, FALSE);
@@ -188,7 +188,7 @@ void samcoupe_state::samcoupe_update_memory(address_space &space)
if (((m_hmpr + 1) & 0x1f) <= PAGE_MASK)
memory = &m_ram->pointer()[((m_hmpr + 1) & PAGE_MASK) * 0x4000];
else
- memory = NULL; /* Attempt to page in non existant ram region */
+ memory = nullptr; /* Attempt to page in non existant ram region */
is_readonly = FALSE;
}
samcoupe_update_bank(space, 4, memory, FALSE);
diff --git a/src/mame/machine/scramble.cpp b/src/mame/machine/scramble.cpp
index b0db1e359e5..af667349e1c 100644
--- a/src/mame/machine/scramble.cpp
+++ b/src/mame/machine/scramble.cpp
@@ -19,7 +19,7 @@ MACHINE_RESET_MEMBER(scramble_state,scramble)
{
MACHINE_RESET_CALL_MEMBER(galaxold);
- if (m_audiocpu != NULL)
+ if (m_audiocpu != nullptr)
sh_init();
}
diff --git a/src/mame/machine/segaic16.cpp b/src/mame/machine/segaic16.cpp
index 36e9d31ffe8..ee171e9af70 100644
--- a/src/mame/machine/segaic16.cpp
+++ b/src/mame/machine/segaic16.cpp
@@ -110,16 +110,16 @@ void sega_16bit_common_base::palette_init()
double weights_normal[6];
compute_resistor_weights(0, 255, -1.0,
6, resistances_normal, weights_normal, 0, 0,
- 0, NULL, NULL, 0, 0,
- 0, NULL, NULL, 0, 0);
+ 0, nullptr, nullptr, 0, 0,
+ 0, nullptr, nullptr, 0, 0);
// compute weight table for shadow/hilight palette entries
static const int resistances_sh[6] = { 3900, 2000, 1000, 1000/2, 1000/4, 470 };
double weights_sh[6];
compute_resistor_weights(0, 255, -1.0,
6, resistances_sh, weights_sh, 0, 0,
- 0, NULL, NULL, 0, 0,
- 0, NULL, NULL, 0, 0);
+ 0, nullptr, nullptr, 0, 0,
+ 0, nullptr, nullptr, 0, 0);
// compute R, G, B for each weight
for (int value = 0; value < 32; value++)
@@ -176,10 +176,10 @@ WRITE16_MEMBER( sega_16bit_common_base::paletteram_w )
sega_315_5195_mapper_device::sega_315_5195_mapper_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: device_t(mconfig, SEGA_315_5195_MEM_MAPPER, "Sega 315-5195 Memory Mapper", tag, owner, clock, "sega_315_5195", __FILE__),
- m_cputag(NULL),
- m_cpu(NULL),
- m_space(NULL),
- m_decrypted_space(NULL),
+ m_cputag(nullptr),
+ m_cpu(nullptr),
+ m_space(nullptr),
+ m_decrypted_space(nullptr),
m_curregion(0)
{
}
@@ -505,18 +505,18 @@ void sega_315_5195_mapper_device::device_start()
// find our CPU
m_cpu = siblingdevice<m68000_device>(m_cputag);
- if (m_cpu == NULL)
+ if (m_cpu == nullptr)
throw emu_fatalerror("Unable to find sibling device '%s'", m_cputag);
// if we are mapping an FD1089, tell all the banks
fd1089_base_device *fd1089 = dynamic_cast<fd1089_base_device *>(m_cpu);
- if (fd1089 != NULL)
+ if (fd1089 != nullptr)
for (int banknum = 0; banknum < ARRAY_LENGTH(m_banks); banknum++)
m_banks[banknum].set_decrypt(fd1089);
// if we are mapping an FD1094, register for state change notifications and tell all the banks
fd1094_device *fd1094 = dynamic_cast<fd1094_device *>(m_cpu);
- if (fd1094 != NULL)
+ if (fd1094 != nullptr)
{
fd1094->notify_state_change(fd1094_device::state_change_delegate(FUNC(sega_315_5195_mapper_device::fd1094_state_change), this));
for (int banknum = 0; banknum < ARRAY_LENGTH(m_banks); banknum++)
@@ -525,10 +525,10 @@ void sega_315_5195_mapper_device::device_start()
// find the address space that is to be mapped
m_space = &m_cpu->space(AS_PROGRAM);
- if (m_space == NULL)
+ if (m_space == nullptr)
throw emu_fatalerror("Unable to find program address space on device '%s'", m_cputag);
- m_decrypted_space = m_cpu->has_space(AS_DECRYPTED_OPCODES) ? &m_cpu->space(AS_DECRYPTED_OPCODES) : NULL;
+ m_decrypted_space = m_cpu->has_space(AS_DECRYPTED_OPCODES) ? &m_cpu->space(AS_DECRYPTED_OPCODES) : nullptr;
// register for saves
save_item(NAME(m_regs));
@@ -602,13 +602,13 @@ void sega_315_5195_mapper_device::update_mapping()
//-------------------------------------------------
sega_315_5195_mapper_device::decrypt_bank::decrypt_bank()
- : m_bank(NULL),
- m_decrypted_bank(NULL),
+ : m_bank(nullptr),
+ m_decrypted_bank(nullptr),
m_start(0),
m_end(0),
m_rgnoffs(~0),
- m_srcptr(NULL),
- m_fd1089(NULL)
+ m_srcptr(nullptr),
+ m_fd1089(nullptr)
{
// invalidate all states
reset();
@@ -644,7 +644,7 @@ void sega_315_5195_mapper_device::decrypt_bank::set_decrypt(fd1094_device *fd109
m_fd1094_cache = std::make_unique<fd1094_decryption_cache>(*fd1094);
// clear out all fd1089 stuff
- m_fd1089 = NULL;
+ m_fd1089 = nullptr;
m_fd1089_decrypted.clear();
}
@@ -657,7 +657,7 @@ void sega_315_5195_mapper_device::decrypt_bank::set_decrypt(fd1094_device *fd109
void sega_315_5195_mapper_device::decrypt_bank::set(memory_bank *bank, memory_bank *decrypted_bank, offs_t start, offs_t end, offs_t rgnoffs, UINT8 *src)
{
// ignore if not encrypted
- if (m_fd1089 == NULL && m_fd1094_cache == NULL)
+ if (m_fd1089 == nullptr && m_fd1094_cache == nullptr)
return;
// ignore if nothing is changing
@@ -676,7 +676,7 @@ void sega_315_5195_mapper_device::decrypt_bank::set(memory_bank *bank, memory_ba
m_srcptr = src;
// configure the fd1094 cache
- if (m_fd1094_cache != NULL)
+ if (m_fd1094_cache != nullptr)
m_fd1094_cache->configure(m_start, m_end + 1 - m_start, m_rgnoffs);
// force an update of what we have
@@ -692,11 +692,11 @@ void sega_315_5195_mapper_device::decrypt_bank::set(memory_bank *bank, memory_ba
void sega_315_5195_mapper_device::decrypt_bank::update()
{
// if this isn't a valid state, don't try to do anything
- if (m_bank == NULL || m_srcptr == NULL)
+ if (m_bank == nullptr || m_srcptr == nullptr)
return;
// fd1089 case
- if (m_fd1089 != NULL)
+ if (m_fd1089 != nullptr)
{
m_fd1089_decrypted.resize((m_end + 1 - m_start) / 2);
m_fd1089->decrypt(m_start, m_end + 1 - m_start, m_rgnoffs, &m_fd1089_decrypted[0], reinterpret_cast<UINT16 *>(m_srcptr));
@@ -704,7 +704,7 @@ void sega_315_5195_mapper_device::decrypt_bank::update()
}
// fd1094 case
- if (m_fd1094_cache != NULL)
+ if (m_fd1094_cache != nullptr)
m_decrypted_bank->set_base(m_fd1094_cache->decrypted_opcodes(m_fd1094_cache->fd1094().state()));
}
diff --git a/src/mame/machine/segaic16.h b/src/mame/machine/segaic16.h
index cc2a2d73c26..6e98d8b7688 100644
--- a/src/mame/machine/segaic16.h
+++ b/src/mame/machine/segaic16.h
@@ -135,12 +135,12 @@ private:
// configuration
void set_decrypt(fd1089_base_device *fd1089);
void set_decrypt(fd1094_device *fd1094);
- void clear() { set(NULL, NULL, 0, 0, ~0, NULL); }
+ void clear() { set(nullptr, nullptr, 0, 0, ~0, nullptr); }
void set(memory_bank *bank, memory_bank *decrypted_bank, offs_t start, offs_t end, offs_t rgnoffs, UINT8 *src);
// updating
void update();
- void reset() { m_fd1089_decrypted.clear(); if (m_fd1094_cache != NULL) m_fd1094_cache->reset(); }
+ void reset() { m_fd1089_decrypted.clear(); if (m_fd1094_cache != nullptr) m_fd1094_cache->reset(); }
private:
// internal state
diff --git a/src/mame/machine/seicop.cpp b/src/mame/machine/seicop.cpp
index f5868cb6c9a..d5640aa6881 100644
--- a/src/mame/machine/seicop.cpp
+++ b/src/mame/machine/seicop.cpp
@@ -24,7 +24,7 @@ const device_type SEIBU_COP_BOOTLEG = &device_creator<seibu_cop_bootleg_device>;
seibu_cop_bootleg_device::seibu_cop_bootleg_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: device_t(mconfig, SEIBU_COP_BOOTLEG, "Seibu COP (Bootleg)", tag, owner, clock, "seibu_cop_boot", __FILE__),
- m_cop_mcu_ram(NULL),
+ m_cop_mcu_ram(nullptr),
m_raiden2cop(*this, ":raiden2cop")
{
}
diff --git a/src/mame/machine/sgi.cpp b/src/mame/machine/sgi.cpp
index 797f27eb58b..fe2259b5219 100644
--- a/src/mame/machine/sgi.cpp
+++ b/src/mame/machine/sgi.cpp
@@ -32,7 +32,7 @@ const device_type SGI_MC = &device_creator<sgi_mc_device>;
sgi_mc_device::sgi_mc_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: device_t(mconfig, SGI_MC, "SGI Memory Controller", tag, owner, clock, "sgi_mc", __FILE__),
- m_tUpdateTimer(NULL),
+ m_tUpdateTimer(nullptr),
m_nCPUControl0(0),
m_nCPUControl1(0),
m_nWatchdog(0),
diff --git a/src/mame/machine/slapstic.cpp b/src/mame/machine/slapstic.cpp
index 5adf0c91d7f..4ff2fe4a2e3 100644
--- a/src/mame/machine/slapstic.cpp
+++ b/src/mame/machine/slapstic.cpp
@@ -716,7 +716,7 @@ static const struct slapstic_data slapstic118 =
static const struct slapstic_data *const slapstic_table[] =
{
&slapstic101, /* NOT confirmed! */
- NULL, /* never seen */
+ nullptr, /* never seen */
&slapstic103,
&slapstic104,
&slapstic105,
diff --git a/src/mame/machine/smartmed.cpp b/src/mame/machine/smartmed.cpp
index 32e9c53bcaa..b3147c49316 100644
--- a/src/mame/machine/smartmed.cpp
+++ b/src/mame/machine/smartmed.cpp
@@ -78,7 +78,7 @@ nand_device::nand_device(const machine_config &mconfig, const char *tag, device_
m_page_total_size(0),
m_num_pages(0),
m_log2_pages_per_block(0),
- m_pagereg(NULL),
+ m_pagereg(nullptr),
m_id_len(0),
m_col_address_cycles(0),
m_row_address_cycles(0),
@@ -94,7 +94,7 @@ nand_device::nand_device(const machine_config &mconfig, device_type type, const
m_page_total_size(0),
m_num_pages(0),
m_log2_pages_per_block(0),
- m_pagereg(NULL),
+ m_pagereg(nullptr),
m_id_len(0),
m_col_address_cycles(0),
m_row_address_cycles(0),
@@ -109,8 +109,8 @@ nand_device::nand_device(const machine_config &mconfig, device_type type, const
*/
void nand_device::device_start()
{
- m_data_ptr = NULL;
- m_data_uid_ptr = NULL;
+ m_data_ptr = nullptr;
+ m_data_uid_ptr = nullptr;
m_mode = SM_M_INIT;
m_pointer_mode = SM_PM_A;
m_page_addr = 0;
@@ -335,8 +335,8 @@ void smartmedia_image_device::call_unload()
m_page_total_size = 0;
m_num_pages = 0;
m_log2_pages_per_block = 0;
- m_data_ptr = NULL;
- m_data_uid_ptr = NULL;
+ m_data_ptr = nullptr;
+ m_data_uid_ptr = nullptr;
m_mode = SM_M_INIT;
m_pointer_mode = SM_PM_A;
m_page_addr = 0;
diff --git a/src/mame/machine/smartmed.h b/src/mame/machine/smartmed.h
index 4f15cf35a0f..5e5b2f1c80d 100644
--- a/src/mame/machine/smartmed.h
+++ b/src/mame/machine/smartmed.h
@@ -215,7 +215,7 @@ public:
virtual bool is_reset_on_load() const { return 0; }
virtual const char *image_interface() const { return "sm_memc"; }
virtual const char *file_extensions() const { return "smc"; }
- virtual const option_guide *create_option_guide() const { return NULL; }
+ virtual const option_guide *create_option_guide() const { return nullptr; }
virtual bool call_load();
virtual void call_unload();
diff --git a/src/mame/machine/sms.cpp b/src/mame/machine/sms.cpp
index 32081091088..86fb9114bc0 100644
--- a/src/mame/machine/sms.cpp
+++ b/src/mame/machine/sms.cpp
@@ -854,9 +854,9 @@ void sms_state::setup_bios()
m_BIOS = memregion("user1")->base();
m_bios_page_count = (m_BIOS ? memregion("user1")->bytes() / 0x4000 : 0);
- if (m_BIOS == NULL || m_BIOS[0] == 0x00)
+ if (m_BIOS == nullptr || m_BIOS[0] == 0x00)
{
- m_BIOS = NULL;
+ m_BIOS = nullptr;
m_has_bios_0400 = 0;
m_has_bios_2000 = 0;
m_has_bios_full = 0;
@@ -890,7 +890,7 @@ MACHINE_START_MEMBER(sms_state,sms)
m_expslot = machine().device<sms_expansion_slot_device>("exp");
m_space = &m_maincpu->space(AS_PROGRAM);
- if (m_mainram == NULL)
+ if (m_mainram == nullptr)
{
m_mainram = auto_alloc_array_clear(machine(), UINT8, 0x2000);
save_pointer(NAME(m_mainram), 0x2000);
diff --git a/src/mame/machine/sonydriv.cpp b/src/mame/machine/sonydriv.cpp
index f53fcb77e20..3c70a4664e7 100644
--- a/src/mame/machine/sonydriv.cpp
+++ b/src/mame/machine/sonydriv.cpp
@@ -280,7 +280,7 @@ int sony_read_status(device_t *device)
f = &sony.floppy[sony.floppy_select];
cur_image = floppy_get_device_by_type(device->machine(), FLOPPY_TYPE_SONY, sony.floppy_select);
if (!cur_image->exists())
- cur_image = NULL;
+ cur_image = nullptr;
switch(action) {
case 0x00: /* Step direction */
@@ -416,7 +416,7 @@ static void sony_doaction(device_t *device)
f = &sony.floppy[sony.floppy_select];
cur_image = floppy_get_device_by_type(device->machine(), FLOPPY_TYPE_SONY, sony.floppy_select);
if (!cur_image->exists())
- cur_image = NULL;
+ cur_image = nullptr;
switch(action)
{
@@ -549,8 +549,8 @@ void sonydriv_floppy_image_device::device_start()
sony.floppy[1].is_fdhd = 0;
sony.floppy[0].is_400k = 0;
sony.floppy[1].is_400k = 0;
- sony.floppy[0].loadedtrack_data = NULL;
- sony.floppy[1].loadedtrack_data = NULL;
+ sony.floppy[0].loadedtrack_data = nullptr;
+ sony.floppy[1].loadedtrack_data = nullptr;
sony.floppy[0].head = 0;
sony.floppy[1].head = 0;
sony.rotation_speed = 0;
diff --git a/src/mame/machine/special.cpp b/src/mame/machine/special.cpp
index 4bbcdbf4dd9..bb1c7f64f31 100644
--- a/src/mame/machine/special.cpp
+++ b/src/mame/machine/special.cpp
@@ -244,7 +244,7 @@ WRITE_LINE_MEMBER( special_state::fdc_drq )
WRITE8_MEMBER( special_state::specimx_disk_ctrl_w )
{
static const char *names[] = { "fd0", "fd1"};
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
floppy_connector *con = machine().device<floppy_connector>(names[m_drive & 1]);
if(con)
floppy = con->get_device();
diff --git a/src/mame/machine/st0016.cpp b/src/mame/machine/st0016.cpp
index 5dcfb73fa0e..3abdc4eafaf 100644
--- a/src/mame/machine/st0016.cpp
+++ b/src/mame/machine/st0016.cpp
@@ -587,7 +587,7 @@ void st0016_cpu_device::startup()
/* find first empty slot to decode gfx */
for (gfx_index = 0; gfx_index < MAX_GFX_ELEMENTS; gfx_index++)
- if (m_gfxdecode->gfx(gfx_index) == 0)
+ if (m_gfxdecode->gfx(gfx_index) == nullptr)
break;
assert(gfx_index != MAX_GFX_ELEMENTS);
diff --git a/src/mame/machine/super80.cpp b/src/mame/machine/super80.cpp
index b77c04b68fd..27b6d614e7d 100644
--- a/src/mame/machine/super80.cpp
+++ b/src/mame/machine/super80.cpp
@@ -143,7 +143,7 @@ WRITE8_MEMBER( super80_state::port3f_w )
// m_fdc->58(BIT(data, 0)); 5/8 pin not emulated in wd_fdc
m_fdc->enmf_w(BIT(data,1));
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (BIT(data, 2)) floppy = m_floppy0->get_device();
if (BIT(data, 3)) floppy = m_floppy1->get_device();
//if (BIT(data, 4)) floppy = m_floppy2->get_device();
diff --git a/src/mame/machine/svi318.cpp b/src/mame/machine/svi318.cpp
index 89ea87ce0e8..b34b6f381fc 100644
--- a/src/mame/machine/svi318.cpp
+++ b/src/mame/machine/svi318.cpp
@@ -63,7 +63,7 @@ DEVICE_IMAGE_LOAD_MEMBER( svi318_state, svi318_cart )
m_cart->rom_alloc(size, GENERIC_ROM8_WIDTH, ENDIANNESS_LITTLE);
m_cart->common_load_rom(m_cart->get_rom_base(), size, "rom");
- if (image.software_entry() == NULL && !cart_verify(m_cart->get_rom_base()))
+ if (image.software_entry() == nullptr && !cart_verify(m_cart->get_rom_base()))
return IMAGE_INIT_FAIL;
return IMAGE_INIT_PASS;
@@ -222,7 +222,7 @@ WRITE_LINE_MEMBER(svi318_state::fdc_drq_w)
WRITE8_MEMBER(svi318_state::fdc_drive_motor_w)
{
- m_floppy = NULL;
+ m_floppy = nullptr;
if (BIT(data, 0)) m_floppy = m_floppy0->get_device();
if (BIT(data, 1)) m_floppy = m_floppy1->get_device();
diff --git a/src/mame/machine/swtpc09.cpp b/src/mame/machine/swtpc09.cpp
index 29bae501462..71613a8b8ac 100644
--- a/src/mame/machine/swtpc09.cpp
+++ b/src/mame/machine/swtpc09.cpp
@@ -126,7 +126,7 @@ WRITE8_MEMBER ( swtpc09_state::dmf2_control_reg_w )
{
LOG(("swtpc09_dmf2_control_reg_w $%02X\n", data));
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (!BIT(data, 0)) floppy = m_floppy0->get_device();
if (!BIT(data, 1)) floppy = m_floppy1->get_device();
@@ -354,7 +354,7 @@ WRITE8_MEMBER ( swtpc09_state::dmf3_control_reg_w )
{
LOG(("swtpc09_dmf3_control_reg_w $%02X\n", data));
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (BIT(data, 0)) floppy = m_floppy0->get_device();
if (BIT(data, 1)) floppy = m_floppy1->get_device();
@@ -378,7 +378,7 @@ WRITE8_MEMBER ( swtpc09_state::dc4_control_reg_w )
{
LOG(("swtpc09_dc4_control_reg_w $%02X\n", data));
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (BIT(data, 0)) floppy = m_floppy0->get_device();
if (BIT(data, 1)) floppy = m_floppy1->get_device();
diff --git a/src/mame/machine/tait8741.cpp b/src/mame/machine/tait8741.cpp
index c6485a90dda..58df20ca4ed 100644
--- a/src/mame/machine/tait8741.cpp
+++ b/src/mame/machine/tait8741.cpp
@@ -127,7 +127,7 @@ void taito8741_4pack_device::update(int num)
st = &m_taito8741[num];
if( st->connect != -1 )
sst = &m_taito8741[st->connect];
- else sst = 0;
+ else sst = nullptr;
next = -1;
/* check pending command */
switch(st->phase)
diff --git a/src/mame/machine/taitosj.cpp b/src/mame/machine/taitosj.cpp
index 890f66f3393..f32f2fc83df 100644
--- a/src/mame/machine/taitosj.cpp
+++ b/src/mame/machine/taitosj.cpp
@@ -47,7 +47,7 @@ void taitosj_state::machine_reset()
m_zaccept = 1;
m_zready = 0;
m_busreq = 0;
- if (m_mcu != NULL)
+ if (m_mcu != nullptr)
m_mcu->set_input_line(0, CLEAR_LINE);
m_spacecr_prot_value = 0;
diff --git a/src/mame/machine/thomflop.cpp b/src/mame/machine/thomflop.cpp
index 3927f7219af..6252d2ec48a 100644
--- a/src/mame/machine/thomflop.cpp
+++ b/src/mame/machine/thomflop.cpp
@@ -296,7 +296,7 @@ WRITE8_MEMBER( thomson_state::to7_5p14_w )
else if ( offset == 8 )
{
/* drive select */
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (BIT(data, 1)) floppy = fdc->subdevice<floppy_connector>("0")->get_device();
if (BIT(data, 2)) floppy = fdc->subdevice<floppy_connector>("1")->get_device();
@@ -925,7 +925,7 @@ legacy_floppy_image_device * thomson_state::thmfc_floppy_image()
int thomson_state::thmfc_floppy_is_qdd ( legacy_floppy_image_device *image )
{
- if (image==NULL) return 0;
+ if (image==nullptr) return 0;
if (!image->exists()) return 0;
return image->length()==51200; // idf QDD
}
@@ -1894,18 +1894,18 @@ void thomson_state::thomson_index_callback(legacy_floppy_image_device *device, i
switch ( to7_controller_type )
{
case 1:
- to7_5p14_index_pulse_callback(NULL, device, state);
+ to7_5p14_index_pulse_callback(nullptr, device, state);
break;
case 2:
break;
case 3:
- thmfc_floppy_index_pulse_cb(NULL, device, state);
+ thmfc_floppy_index_pulse_cb(nullptr, device, state);
break;
case 4:
- to7_qdd_index_pulse_cb(NULL, device, state);
+ to7_qdd_index_pulse_cb(nullptr, device, state);
break;
default:
diff --git a/src/mame/machine/thomson.cpp b/src/mame/machine/thomson.cpp
index 240b004141a..b7deec216ee 100644
--- a/src/mame/machine/thomson.cpp
+++ b/src/mame/machine/thomson.cpp
@@ -363,7 +363,7 @@ DEVICE_IMAGE_LOAD_MEMBER( thomson_state, to7_cartridge )
offs_t size;
char name[129];
- if (image.software_entry() == NULL)
+ if (image.software_entry() == nullptr)
size = image.length();
else
size = image.get_software_region_length("rom");
@@ -383,7 +383,7 @@ DEVICE_IMAGE_LOAD_MEMBER( thomson_state, to7_cartridge )
return IMAGE_INIT_FAIL;
}
- if (image.software_entry() == NULL)
+ if (image.software_entry() == nullptr)
{
if ( image.fread( pos, size ) != size )
{
@@ -631,7 +631,7 @@ static MACHINE_CONFIG_FRAGMENT( to7_io_line )
MCFG_PIA_IRQA_HANDLER(DEVWRITELINE("^", thomson_state, thom_firq_1))
MCFG_PIA_IRQB_HANDLER(DEVWRITELINE("^", thomson_state, thom_firq_1))
- MCFG_RS232_PORT_ADD("rs232", default_rs232_devices, NULL)
+ MCFG_RS232_PORT_ADD("rs232", default_rs232_devices, nullptr)
MCFG_RS232_RXD_HANDLER(WRITELINE(to7_io_line_device, write_rxd))
MCFG_RS232_CTS_HANDLER(WRITELINE(to7_io_line_device, write_cts))
MCFG_RS232_DSR_HANDLER(WRITELINE(to7_io_line_device, write_dsr))
@@ -1494,7 +1494,7 @@ DEVICE_IMAGE_LOAD_MEMBER( thomson_state, mo5_cartridge )
int j;
char name[129];
- if (image.software_entry() == NULL)
+ if (image.software_entry() == nullptr)
size = image.length();
else
size = image.get_software_region_length("rom");
@@ -1514,7 +1514,7 @@ DEVICE_IMAGE_LOAD_MEMBER( thomson_state, mo5_cartridge )
return IMAGE_INIT_FAIL;
}
- if (image.software_entry() == NULL)
+ if (image.software_entry() == nullptr)
{
if ( image.fread(pos, size ) != size )
{
diff --git a/src/mame/machine/ticket.cpp b/src/mame/machine/ticket.cpp
index a80d951a973..595a22b40a9 100644
--- a/src/mame/machine/ticket.cpp
+++ b/src/mame/machine/ticket.cpp
@@ -49,7 +49,7 @@ ticket_dispenser_device::ticket_dispenser_device(const machine_config &mconfig,
m_ticketnotdispensed(0),
m_status(0),
m_power(0),
- m_timer(NULL)
+ m_timer(nullptr)
{
}
diff --git a/src/mame/machine/tnzs.cpp b/src/mame/machine/tnzs.cpp
index a855f81b9b8..108a5fa1522 100644
--- a/src/mame/machine/tnzs.cpp
+++ b/src/mame/machine/tnzs.cpp
@@ -696,7 +696,7 @@ WRITE8_MEMBER(tnzs_state::tnzs_bankswitch1_w)
/* bit 2 resets the mcu */
if (data & 0x04)
{
- if (m_mcu != NULL && m_mcu->type() == I8742)
+ if (m_mcu != nullptr && m_mcu->type() == I8742)
m_mcu->set_input_line(INPUT_LINE_RESET, PULSE_LINE);
}
/* Coin count and lockout is handled by the i8742 */
diff --git a/src/mame/machine/trs80.cpp b/src/mame/machine/trs80.cpp
index 980176e109e..b2f706028e5 100644
--- a/src/mame/machine/trs80.cpp
+++ b/src/mame/machine/trs80.cpp
@@ -503,7 +503,7 @@ WRITE8_MEMBER( trs80_state::trs80m4_ec_w )
d0 1=select drive 0 */
WRITE8_MEMBER( trs80_state::trs80m4_f4_w )
{
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (BIT(data, 0)) floppy = m_floppy0->get_device();
if (BIT(data, 1)) floppy = m_floppy1->get_device();
@@ -731,7 +731,7 @@ READ8_MEMBER( trs80_state::trs80_irq_status_r )
WRITE8_MEMBER( trs80_state::trs80_motor_w )
{
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (BIT(data, 0)) floppy = m_floppy0->get_device();
if (BIT(data, 1)) floppy = m_floppy1->get_device();
diff --git a/src/mame/machine/vector06.cpp b/src/mame/machine/vector06.cpp
index ba944cef8fd..1d1ff0fa417 100644
--- a/src/mame/machine/vector06.cpp
+++ b/src/mame/machine/vector06.cpp
@@ -138,7 +138,7 @@ TIMER_CALLBACK_MEMBER(vector06_state::reset_check_callback)
WRITE8_MEMBER( vector06_state::vector06_disc_w )
{
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
switch (data & 0x01)
{
diff --git a/src/mame/machine/volfied.cpp b/src/mame/machine/volfied.cpp
index 7776340d11d..498093a5855 100644
--- a/src/mame/machine/volfied.cpp
+++ b/src/mame/machine/volfied.cpp
@@ -259,7 +259,7 @@ static const UINT16 palette_data_11[0x50] =
static const UINT16 *const palette_data_lookup[] =
{
- 0,
+ nullptr,
palette_data_01,
palette_data_02,
palette_data_03,
diff --git a/src/mame/machine/vsnes.cpp b/src/mame/machine/vsnes.cpp
index 8e210a75c95..d07cb99b25d 100644
--- a/src/mame/machine/vsnes.cpp
+++ b/src/mame/machine/vsnes.cpp
@@ -204,7 +204,7 @@ MACHINE_START_MEMBER(vsnes_state,vsnes)
/* establish chr banks */
/* bank 1 is used already! */
/* DRIVER_INIT is called first - means we can handle this different for VRAM games! */
- if (NULL != m_vrom[0])
+ if (nullptr != m_vrom[0])
{
for (i = 0; i < 8; i++)
{
diff --git a/src/mame/machine/vtech2.cpp b/src/mame/machine/vtech2.cpp
index 5929b4aab47..bbc7d427cad 100644
--- a/src/mame/machine/vtech2.cpp
+++ b/src/mame/machine/vtech2.cpp
@@ -319,7 +319,7 @@ void vtech2_state::laser_get_track()
sprintf(m_laser_frame_message, "#%d get track %02d", m_laser_drive, m_laser_track_x2[m_laser_drive]/2);
m_laser_frame_time = 30;
/* drive selected or and image file ok? */
- if( m_laser_drive >= 0 && laser_file() != NULL )
+ if( m_laser_drive >= 0 && laser_file() != nullptr )
{
int size, offs;
device_image_interface *image = dynamic_cast<device_image_interface *>(laser_file());
@@ -337,7 +337,7 @@ void vtech2_state::laser_put_track()
{
device_image_interface *image = dynamic_cast<device_image_interface *>(laser_file());
/* drive selected and image file ok? */
- if( m_laser_drive >= 0 && laser_file() != NULL )
+ if( m_laser_drive >= 0 && laser_file() != nullptr )
{
int size, offs;
offs = TRKSIZE_VZ * m_laser_track_x2[m_laser_drive]/2;
diff --git a/src/mame/machine/wpc_lamp.cpp b/src/mame/machine/wpc_lamp.cpp
index c151bc257a0..2201ba40805 100644
--- a/src/mame/machine/wpc_lamp.cpp
+++ b/src/mame/machine/wpc_lamp.cpp
@@ -9,7 +9,7 @@ const device_type WPC_LAMP = &device_creator<wpc_lamp_device>;
wpc_lamp_device::wpc_lamp_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) :
device_t(mconfig, WPC_LAMP, "Williams Pinball Controller Lamp Control", tag, owner, clock, "wpc_lamp", __FILE__)
{
- names = NULL;
+ names = nullptr;
}
wpc_lamp_device::~wpc_lamp_device()
diff --git a/src/mame/machine/wpc_out.cpp b/src/mame/machine/wpc_out.cpp
index 4532f70581b..d9d73f7b7b2 100644
--- a/src/mame/machine/wpc_out.cpp
+++ b/src/mame/machine/wpc_out.cpp
@@ -9,7 +9,7 @@ const device_type WPC_OUT = &device_creator<wpc_out_device>;
wpc_out_device::wpc_out_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) :
device_t(mconfig, WPC_OUT, "Williams Pinball Controller Output Control", tag, owner, clock, "wpc_out", __FILE__)
{
- names = NULL;
+ names = nullptr;
}
wpc_out_device::~wpc_out_device()
diff --git a/src/mame/machine/x68k_hdc.h b/src/mame/machine/x68k_hdc.h
index 73fc210fa63..48f21fa6f99 100644
--- a/src/mame/machine/x68k_hdc.h
+++ b/src/mame/machine/x68k_hdc.h
@@ -92,9 +92,9 @@ public:
virtual bool is_creatable() const { return 1; }
virtual bool must_be_loaded() const { return 0; }
virtual bool is_reset_on_load() const { return 0; }
- virtual const char *image_interface() const { return NULL; }
+ virtual const char *image_interface() const { return nullptr; }
virtual const char *file_extensions() const { return "hdf"; }
- virtual const option_guide *create_option_guide() const { return NULL; }
+ virtual const option_guide *create_option_guide() const { return nullptr; }
virtual bool call_create(int format_type, option_resolution *format_options);
DECLARE_WRITE16_MEMBER( hdc_w );
diff --git a/src/mame/machine/xbox.cpp b/src/mame/machine/xbox.cpp
index ac0b3ea2b0f..f584f62ce1d 100644
--- a/src/mame/machine/xbox.cpp
+++ b/src/mame/machine/xbox.cpp
@@ -290,7 +290,7 @@ static void grab_vprog_command(running_machine &machine, int ref, int params, co
return;
if ((param[0][0] == 0) || (strlen(param[0]) > 127))
return;
- if ((fil = fopen(param[0], "wb")) == NULL)
+ if ((fil = fopen(param[0], "wb")) == nullptr)
return;
for (int n = 0; n < 136; n++) {
chst->nvidia_nv2a->debug_grab_vertex_program_slot(n, instruction);
@@ -829,7 +829,7 @@ ohci_function_device::ohci_function_device()
address = 0;
controldir = 0;
remain = 0;
- position = NULL;
+ position = nullptr;
}
void ohci_function_device::execute_reset()
@@ -846,7 +846,7 @@ int ohci_function_device::execute_transfer(int address, int endpoint, int pid, U
controldir = p->bmRequestType & 128;
// case !=0, in data stage and out status stage
// case ==0, out data stage and in status stage
- position = NULL;
+ position = nullptr;
remain = p->wLength;
if ((p->bmRequestType & 0x60) == 0) {
switch (p->bRequest) {
@@ -871,7 +871,7 @@ int ohci_function_device::execute_transfer(int address, int endpoint, int pid, U
if (size > remain)
size = remain;
if (controldir != 0) {
- if (position != NULL)
+ if (position != nullptr)
memcpy(buffer, position, size);
position = position + size;
remain = remain - size;
@@ -883,7 +883,7 @@ int ohci_function_device::execute_transfer(int address, int endpoint, int pid, U
if (size > remain)
size = remain;
if (controldir == 0) {
- if (position != NULL)
+ if (position != nullptr)
memcpy(position, buffer, size);
position = position + size;
remain = remain - size;
diff --git a/src/mame/machine/z80ne.cpp b/src/mame/machine/z80ne.cpp
index 3e5bce4522e..657bf01fc25 100644
--- a/src/mame/machine/z80ne.cpp
+++ b/src/mame/machine/z80ne.cpp
@@ -651,7 +651,7 @@ WRITE8_MEMBER(z80ne_state::lx390_motor_w)
d1 1=select drive 1
d0 1=select drive 0 */
- floppy_image_device *floppy = NULL;
+ floppy_image_device *floppy = nullptr;
if (BIT(data, 0)) floppy = m_floppy0->get_device();
if (BIT(data, 1)) floppy = m_floppy1->get_device();
diff --git a/src/mame/machine/zs01.cpp b/src/mame/machine/zs01.cpp
index 84fda99e05b..613a3cdcc1a 100644
--- a/src/mame/machine/zs01.cpp
+++ b/src/mame/machine/zs01.cpp
@@ -47,7 +47,7 @@ zs01_device::zs01_device( const machine_config &mconfig, const char *tag, device
void zs01_device::device_start()
{
m_ds2401 = siblingdevice<ds2401_device>(m_ds2401_tag);
- if( m_ds2401 == NULL )
+ if( m_ds2401 == nullptr )
{
logerror( "ds2401 '%s' not found\n", m_ds2401_tag );
}
diff --git a/src/mame/machine/zx8302.cpp b/src/mame/machine/zx8302.cpp
index 6866b61f290..16e06522aa0 100644
--- a/src/mame/machine/zx8302.cpp
+++ b/src/mame/machine/zx8302.cpp
@@ -149,7 +149,7 @@ zx8302_device::zx8302_device(const machine_config &mconfig, const char *tag, dev
m_cts2(0),
m_idr(1),
m_irq(0),
- m_ctr(time(NULL) + RTC_BASE_ADJUST),
+ m_ctr(time(nullptr) + RTC_BASE_ADJUST),
m_status(0),
m_comdata_from_ipc(1),
m_comdata_to_cpu(1),