summaryrefslogtreecommitdiffstatshomepage
path: root/src
diff options
context:
space:
mode:
author Vas Crabb <vas@vastheman.com>2018-04-30 23:32:41 +1000
committer Vas Crabb <vas@vastheman.com>2018-04-30 23:32:41 +1000
commitb60c852f119db04564731fa86d73e0a986771258 (patch)
treef3f48148a13484a407b7054c78239258708c5a18 /src
parent89b356a0f5d874f2cabe2e0a96ccfb611b735109 (diff)
Set finder tag relative to current device being configured rather than
the finder's owner. This meand you no longer need to care about the your relationship to the object being configured and a lot of ^ and : can disappear. There's a bit reduction in string pasting in macros from this. Yes, I have to make this apply to devcb etc. as well, but that's a job for another day. There's probably at least one thing broken by this where optional objects are involved. Most things can be solved by just getting rid of the now-problematic ^ and : prefixes.
Diffstat (limited to 'src')
-rw-r--r--src/devices/bus/a2bus/pc_xporter.cpp2
-rw-r--r--src/devices/bus/bml3/bml3bus.h2
-rw-r--r--src/devices/bus/cbmiec/c1571.cpp2
-rw-r--r--src/devices/bus/cbmiec/fd2000.cpp6
-rw-r--r--src/devices/bus/ep64/exp.h2
-rw-r--r--src/devices/bus/intellec4/intellec4.h12
-rw-r--r--src/devices/bus/iq151/iq151.h2
-rw-r--r--src/devices/bus/isa/isa.cpp17
-rw-r--r--src/devices/bus/isa/isa.h11
-rw-r--r--src/devices/bus/macpds/pds_tpdfpd.cpp5
-rw-r--r--src/devices/bus/macpds/pds_tpdfpd.h1
-rw-r--r--src/devices/bus/msx_slot/bunsetsu.h4
-rw-r--r--src/devices/bus/msx_slot/disk.h12
-rw-r--r--src/devices/bus/msx_slot/fs4600.h2
-rw-r--r--src/devices/bus/msx_slot/music.h2
-rw-r--r--src/devices/bus/msx_slot/panasonic08.h2
-rw-r--r--src/devices/bus/msx_slot/rom.h2
-rw-r--r--src/devices/bus/msx_slot/sony08.h5
-rw-r--r--src/devices/bus/nubus/nubus_48gc.cpp7
-rw-r--r--src/devices/bus/nubus/nubus_48gc.h1
-rw-r--r--src/devices/bus/nubus/nubus_m2hires.cpp5
-rw-r--r--src/devices/bus/nubus/nubus_m2hires.h1
-rw-r--r--src/devices/bus/nubus/nubus_m2video.cpp5
-rw-r--r--src/devices/bus/nubus/nubus_m2video.h1
-rw-r--r--src/devices/bus/nubus/nubus_radiustpd.cpp5
-rw-r--r--src/devices/bus/nubus/nubus_radiustpd.h1
-rw-r--r--src/devices/bus/nubus/nubus_spec8.cpp3
-rw-r--r--src/devices/bus/nubus/nubus_spec8.h1
-rw-r--r--src/devices/bus/nubus/nubus_specpdq.cpp3
-rw-r--r--src/devices/bus/nubus/nubus_specpdq.h1
-rw-r--r--src/devices/bus/nubus/nubus_wsportrait.cpp5
-rw-r--r--src/devices/bus/nubus/nubus_wsportrait.h1
-rw-r--r--src/devices/bus/nubus/pds30_30hr.cpp5
-rw-r--r--src/devices/bus/nubus/pds30_30hr.h1
-rw-r--r--src/devices/bus/nubus/pds30_cb264.cpp5
-rw-r--r--src/devices/bus/nubus/pds30_cb264.h1
-rw-r--r--src/devices/bus/nubus/pds30_mc30.cpp5
-rw-r--r--src/devices/bus/nubus/pds30_mc30.h1
-rw-r--r--src/devices/bus/nubus/pds30_procolor816.cpp5
-rw-r--r--src/devices/bus/nubus/pds30_procolor816.h1
-rw-r--r--src/devices/bus/nubus/pds30_sigmalview.cpp5
-rw-r--r--src/devices/bus/nubus/pds30_sigmalview.h1
-rw-r--r--src/devices/bus/sms_ctrl/lphaser.cpp2
-rw-r--r--src/devices/cpu/avr8/avr8.h2
-rw-r--r--src/devices/cpu/esrip/esrip.h2
-rw-r--r--src/devices/machine/genpc.h16
-rw-r--r--src/devices/machine/k033906.h2
-rw-r--r--src/devices/machine/k053252.h2
-rw-r--r--src/devices/machine/k056230.h2
-rw-r--r--src/devices/machine/laserdsc.h2
-rw-r--r--src/devices/machine/legscsi.h2
-rw-r--r--src/devices/machine/mc68328.h2
-rw-r--r--src/devices/machine/msm6253.h28
-rw-r--r--src/devices/machine/ra17xx.h5
-rw-r--r--src/devices/machine/s3c2400.h4
-rw-r--r--src/devices/machine/s3c2410.h4
-rw-r--r--src/devices/machine/s3c2440.h4
-rw-r--r--src/devices/machine/smpc.h2
-rw-r--r--src/devices/machine/tc009xlvc.h2
-rw-r--r--src/devices/machine/tmp68301.h2
-rw-r--r--src/devices/machine/upd4701.h4
-rw-r--r--src/devices/machine/upd71071.h2
-rw-r--r--src/devices/sound/c6280.h2
-rw-r--r--src/devices/sound/es8712.h2
-rw-r--r--src/devices/sound/gaelco.h2
-rw-r--r--src/devices/sound/tms5110.h2
-rw-r--r--src/devices/video/315_5313.h2
-rw-r--r--src/devices/video/ef9345.h2
-rw-r--r--src/devices/video/ef9364.h2
-rw-r--r--src/devices/video/ef9365.h2
-rw-r--r--src/devices/video/gb_lcd.h8
-rw-r--r--src/devices/video/imagetek_i4100.h2
-rw-r--r--src/devices/video/mb_vcu.h4
-rw-r--r--src/devices/video/mos6566.h2
-rw-r--r--src/devices/video/msm6222b.cpp4
-rw-r--r--src/devices/video/ppu2c0x.h2
-rw-r--r--src/devices/video/ramdac.h2
-rw-r--r--src/devices/video/tms9927.h2
-rw-r--r--src/devices/video/vic4567.h2
-rw-r--r--src/emu/devfind.cpp25
-rw-r--r--src/emu/devfind.h32
-rw-r--r--src/emu/divideo.cpp54
-rw-r--r--src/emu/divideo.h8
-rw-r--r--src/emu/emupal.h2
-rw-r--r--src/emu/mconfig.h3
-rw-r--r--src/emu/tilemap.h2
-rw-r--r--src/mame/audio/namco52.h2
-rw-r--r--src/mame/audio/namco54.h2
-rw-r--r--src/mame/audio/seibu.h4
-rw-r--r--src/mame/audio/taitosnd.h4
-rw-r--r--src/mame/drivers/4enlinea.cpp2
-rw-r--r--src/mame/drivers/asst128.cpp2
-rw-r--r--src/mame/drivers/at.cpp2
-rw-r--r--src/mame/drivers/ct486.cpp2
-rw-r--r--src/mame/drivers/fruitpc.cpp2
-rw-r--r--src/mame/drivers/gijoe.cpp2
-rw-r--r--src/mame/drivers/indiana.cpp2
-rw-r--r--src/mame/drivers/lethal.cpp2
-rw-r--r--src/mame/drivers/magtouch.cpp2
-rw-r--r--src/mame/drivers/mc1502.cpp2
-rw-r--r--src/mame/drivers/model2.cpp4
-rw-r--r--src/mame/drivers/moo.cpp2
-rw-r--r--src/mame/drivers/myb3k.cpp2
-rw-r--r--src/mame/drivers/mystwarr.cpp2
-rw-r--r--src/mame/drivers/pc1512.cpp4
-rw-r--r--src/mame/drivers/pcat_dyn.cpp2
-rw-r--r--src/mame/drivers/plygonet.cpp2
-rw-r--r--src/mame/drivers/poisk1.cpp2
-rw-r--r--src/mame/drivers/pt68k4.cpp4
-rw-r--r--src/mame/drivers/rungun.cpp2
-rw-r--r--src/mame/drivers/savquest.cpp2
-rw-r--r--src/mame/drivers/tandy1t.cpp2
-rw-r--r--src/mame/drivers/vis.cpp10
-rw-r--r--src/mame/drivers/wpc_an.cpp2
-rw-r--r--src/mame/drivers/wpc_dot.cpp2
-rw-r--r--src/mame/drivers/wpc_flip1.cpp2
-rw-r--r--src/mame/drivers/wpc_flip2.cpp2
-rw-r--r--src/mame/drivers/xexex.cpp2
-rw-r--r--src/mame/drivers/xmen.cpp4
-rw-r--r--src/mame/machine/awboard.h2
-rw-r--r--src/mame/machine/deco_irq.h2
-rw-r--r--src/mame/machine/hpc3.h8
-rw-r--r--src/mame/machine/ioc2.h4
-rw-r--r--src/mame/machine/mega32x.h2
-rw-r--r--src/mame/machine/namco06.h2
-rw-r--r--src/mame/machine/namco51.h2
-rw-r--r--src/mame/machine/naomim4.h2
-rw-r--r--src/mame/machine/segaic16.h6
-rw-r--r--src/mame/video/atarimo.h2
-rw-r--r--src/mame/video/atarivad.h10
-rw-r--r--src/mame/video/avgdvg.h2
-rw-r--r--src/mame/video/decbac06.h2
-rw-r--r--src/mame/video/deckarn.h2
-rw-r--r--src/mame/video/decmxc06.h2
-rw-r--r--src/mame/video/deco16ic.h2
-rw-r--r--src/mame/video/deco_ace.h2
-rw-r--r--src/mame/video/deco_zoomspr.h2
-rw-r--r--src/mame/video/decocomn.h2
-rw-r--r--src/mame/video/decospr.h2
-rw-r--r--src/mame/video/decrmc3.h6
-rw-r--r--src/mame/video/dooyong.h12
-rw-r--r--src/mame/video/fuukifg.h2
-rw-r--r--src/mame/video/k007121.h2
-rw-r--r--src/mame/video/k007342.h2
-rw-r--r--src/mame/video/k007420.h2
-rw-r--r--src/mame/video/k051960.h2
-rw-r--r--src/mame/video/k052109.h2
-rw-r--r--src/mame/video/k054156_k054157_k056832.h2
-rw-r--r--src/mame/video/kan_pand.h2
-rw-r--r--src/mame/video/kaneko_spr.h2
-rw-r--r--src/mame/video/kaneko_tmap.h2
-rw-r--r--src/mame/video/ladybug.h2
-rw-r--r--src/mame/video/maria.h4
-rw-r--r--src/mame/video/mb60553.h2
-rw-r--r--src/mame/video/pc080sn.h2
-rw-r--r--src/mame/video/pc090oj.h4
-rw-r--r--src/mame/video/segaic16.h2
-rw-r--r--src/mame/video/seta001.h2
-rw-r--r--src/mame/video/snk68_spr.h2
-rw-r--r--src/mame/video/tc0080vco.h2
-rw-r--r--src/mame/video/tc0100scn.h4
-rw-r--r--src/mame/video/tc0110pcr.h2
-rw-r--r--src/mame/video/tc0180vcu.h2
-rw-r--r--src/mame/video/tc0280grd.h4
-rw-r--r--src/mame/video/tc0480scp.h2
-rw-r--r--src/mame/video/vrender0.h2
-rw-r--r--src/mame/video/vs920a.h2
-rw-r--r--src/mame/video/vsystem_spr.h2
-rw-r--r--src/mame/video/vsystem_spr2.h2
-rw-r--r--src/mame/video/vtvideo.h2
-rw-r--r--src/mame/video/zx8301.h2
171 files changed, 332 insertions, 322 deletions
diff --git a/src/devices/bus/a2bus/pc_xporter.cpp b/src/devices/bus/a2bus/pc_xporter.cpp
index fa5559d40b7..94498ee751b 100644
--- a/src/devices/bus/a2bus/pc_xporter.cpp
+++ b/src/devices/bus/a2bus/pc_xporter.cpp
@@ -151,7 +151,7 @@ MACHINE_CONFIG_START(a2bus_pcxporter_device::device_add_mconfig)
MCFG_PIC8259_OUT_INT_CB(INPUTLINE("v30", 0))
MCFG_DEVICE_ADD("isa", ISA8, 0)
- MCFG_ISA8_CPU("^v30")
+ MCFG_ISA8_CPU("v30")
MCFG_ISA_OUT_IRQ2_CB(DEVWRITELINE("pic8259", pic8259_device, ir2_w))
MCFG_ISA_OUT_IRQ3_CB(DEVWRITELINE("pic8259", pic8259_device, ir3_w))
MCFG_ISA_OUT_IRQ4_CB(DEVWRITELINE("pic8259", pic8259_device, ir4_w))
diff --git a/src/devices/bus/bml3/bml3bus.h b/src/devices/bus/bml3/bml3bus.h
index b18642b44ac..be5e419b8f8 100644
--- a/src/devices/bus/bml3/bml3bus.h
+++ b/src/devices/bus/bml3/bml3bus.h
@@ -21,7 +21,7 @@
//**************************************************************************
#define MCFG_BML3BUS_CPU(_cputag) \
- downcast<bml3bus_device &>(*device).set_cputag("^" _cputag);
+ downcast<bml3bus_device &>(*device).set_cputag(_cputag);
#define MCFG_BML3BUS_OUT_NMI_CB(_devcb) \
devcb = &downcast<bml3bus_device &>(*device).set_out_nmi_callback(DEVCB_##_devcb);
diff --git a/src/devices/bus/cbmiec/c1571.cpp b/src/devices/bus/cbmiec/c1571.cpp
index 75b830c11fa..097dbc77cf8 100644
--- a/src/devices/bus/cbmiec/c1571.cpp
+++ b/src/devices/bus/cbmiec/c1571.cpp
@@ -739,7 +739,7 @@ MACHINE_CONFIG_START(mini_chief_device::device_add_mconfig)
MCFG_FLOPPY_DRIVE_ADD_FIXED(C64H156_TAG":0", c1571_floppies, "525qd", c1571_device::floppy_formats)
MCFG_DEVICE_ADD(ISA_BUS_TAG, ISA8, 0)
- MCFG_ISA8_CPU("^" M6502_TAG)
+ MCFG_ISA8_CPU(M6502_TAG)
MCFG_ISA8_SLOT_ADD(ISA_BUS_TAG, "isa1", mini_chief_isa8_cards, "wd1002a_wx1", false)
MACHINE_CONFIG_END
diff --git a/src/devices/bus/cbmiec/fd2000.cpp b/src/devices/bus/cbmiec/fd2000.cpp
index 2f64d86ac28..46dd1151a34 100644
--- a/src/devices/bus/cbmiec/fd2000.cpp
+++ b/src/devices/bus/cbmiec/fd2000.cpp
@@ -275,9 +275,9 @@ fd2000_device::fd2000_device(const machine_config &mconfig, device_type type, co
fd4000_device::fd4000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
: fd2000_device(mconfig, FD4000, tag, owner, clock)
{
- m_maincpu.set_tag(R65C02P4_TAG);
- m_fdc.set_tag(PC8477AV1_TAG);
- m_floppy0.set_tag(PC8477AV1_TAG":0");
+ m_maincpu.set_tag(*this, R65C02P4_TAG);
+ m_fdc.set_tag(*this, PC8477AV1_TAG);
+ m_floppy0.set_tag(*this, PC8477AV1_TAG":0");
}
diff --git a/src/devices/bus/ep64/exp.h b/src/devices/bus/ep64/exp.h
index f870455996c..223be36d7e8 100644
--- a/src/devices/bus/ep64/exp.h
+++ b/src/devices/bus/ep64/exp.h
@@ -68,7 +68,7 @@
MCFG_DEVICE_SLOT_INTERFACE(ep64_expansion_bus_cards, _def_slot, false)
#define MCFG_EP64_EXPANSION_BUS_SLOT_DAVE(_tag) \
- downcast<ep64_expansion_bus_slot_device &>(*device).set_dave_tag("^" _tag);
+ downcast<ep64_expansion_bus_slot_device &>(*device).set_dave_tag(_tag);
#define MCFG_EP64_EXPANSION_BUS_SLOT_IRQ_CALLBACK(_write) \
devcb = &downcast<ep64_expansion_bus_slot_device &>(*device).set_irq_wr_callback(DEVCB_##_write);
diff --git a/src/devices/bus/intellec4/intellec4.h b/src/devices/bus/intellec4/intellec4.h
index cfcec3ee372..c878d00e8c3 100644
--- a/src/devices/bus/intellec4/intellec4.h
+++ b/src/devices/bus/intellec4/intellec4.h
@@ -117,26 +117,26 @@ to implement the card in both systems.
#define MCFG_INTELLEC4_UNIV_SLOT_ADD(bus_tag, slot_tag, clock, slot_intf, def_slot) \
MCFG_DEVICE_ADD(slot_tag, INTELLEC4_UNIV_SLOT, clock) \
MCFG_DEVICE_SLOT_INTERFACE(slot_intf, def_slot, false) \
- downcast<bus::intellec4::univ_slot_device &>(*device).set_bus_tag("^" bus_tag);
+ downcast<bus::intellec4::univ_slot_device &>(*device).set_bus_tag(bus_tag);
#define MCFG_INTELLEC4_UNIV_SLOT_REMOVE(slot_tag) \
MCFG_DEVICE_REMOVE(slot_tag)
#define MCFG_INTELLEC4_UNIV_BUS_ROM_SPACE(tag, space) \
- downcast<bus::intellec4::univ_bus_device &>(*device).set_rom_space("^" tag, space);
+ downcast<bus::intellec4::univ_bus_device &>(*device).set_rom_space(tag, space);
#define MCFG_INTELLEC4_UNIV_BUS_ROM_PORTS_SPACE(tag, space) \
- downcast<bus::intellec4::univ_bus_device &>(*device).set_rom_ports_space("^" tag, space);
+ downcast<bus::intellec4::univ_bus_device &>(*device).set_rom_ports_space(tag, space);
#define MCFG_INTELLEC4_UNIV_BUS_MEMORY_SPACE(tag, space) \
- downcast<bus::intellec4::univ_bus_device &>(*device).set_memory_space("^" tag, space);
+ downcast<bus::intellec4::univ_bus_device &>(*device).set_memory_space(tag, space);
#define MCFG_INTELLEC4_UNIV_BUS_STATUS_SPACE(tag, space) \
- downcast<bus::intellec4::univ_bus_device &>(*device).set_status_space("^" tag, space);
+ downcast<bus::intellec4::univ_bus_device &>(*device).set_status_space(tag, space);
#define MCFG_INTELLEC4_UNIV_BUS_RAM_PORTS_SPACE(tag, space) \
- downcast<bus::intellec4::univ_bus_device &>(*device).set_ram_ports_space("^" tag, space);
+ downcast<bus::intellec4::univ_bus_device &>(*device).set_ram_ports_space(tag, space);
#define MCFG_INTELLEC4_UNIV_BUS_TEST_CB(obj) \
downcast<bus::intellec4::univ_bus_device &>(*device).set_test_out_cb(DEVCB_##obj);
diff --git a/src/devices/bus/iq151/iq151.h b/src/devices/bus/iq151/iq151.h
index baca40fd928..270e47193af 100644
--- a/src/devices/bus/iq151/iq151.h
+++ b/src/devices/bus/iq151/iq151.h
@@ -163,6 +163,6 @@ DECLARE_DEVICE_TYPE(IQ151CART_SLOT, iq151cart_slot_device)
devcb = &downcast<iq151cart_slot_device &>(*device).set_out_drq_callback(DEVCB_##_devcb);
#define MCFG_IQ151CART_SLOT_SCREEN_TAG(screen_tag) \
- downcast<iq151cart_slot_device &>(*device).set_screen_tag(("^" screen_tag));
+ downcast<iq151cart_slot_device &>(*device).set_screen_tag(screen_tag);
#endif // MAME_BUS_IQ151_IQ151_H
diff --git a/src/devices/bus/isa/isa.cpp b/src/devices/bus/isa/isa.cpp
index ac1d7c59651..da54d1aea5c 100644
--- a/src/devices/bus/isa/isa.cpp
+++ b/src/devices/bus/isa/isa.cpp
@@ -31,7 +31,7 @@ isa8_slot_device::isa8_slot_device(const machine_config &mconfig, const char *ta
isa8_slot_device::isa8_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) :
device_t(mconfig, type, tag, owner, clock),
device_slot_interface(mconfig, *this),
- m_owner(nullptr), m_isa_tag(nullptr)
+ m_isa_bus(*this, finder_base::DUMMY_TAG)
{
}
@@ -41,15 +41,15 @@ isa8_slot_device::isa8_slot_device(const machine_config &mconfig, device_type ty
void isa8_slot_device::device_start()
{
- device_isa8_card_interface *dev = dynamic_cast<device_isa8_card_interface *>(get_card_device());
+ device_isa8_card_interface *const dev = dynamic_cast<device_isa8_card_interface *>(get_card_device());
const device_isa16_card_interface *intf;
- device_t *isadev = m_owner->subdevice(m_isa_tag);
if (get_card_device() && get_card_device()->interface(intf))
fatalerror("ISA16 device in ISA8 slot\n");
- if (dev) dev->set_isabus(isadev);
+ if (dev) dev->set_isabus(m_isa_bus);
+
// tell isa bus that there is one slot with the specified tag
- dynamic_cast<isa8_device *>(isadev)->add_slot(tag());
+ downcast<isa8_device &>(*m_isa_bus).add_slot(tag());
}
@@ -78,11 +78,10 @@ isa16_slot_device::isa16_slot_device(const machine_config &mconfig, const char *
void isa16_slot_device::device_start()
{
- device_isa8_card_interface *dev = dynamic_cast<device_isa8_card_interface *>(get_card_device());
- device_t *isadev = m_owner->subdevice(m_isa_tag);
- if (dev) dev->set_isabus(isadev);
+ device_isa8_card_interface *const dev = dynamic_cast<device_isa8_card_interface *>(get_card_device());
+ if (dev) dev->set_isabus(m_isa_bus);
// tell isa bus that there is one slot with the specified tag
- dynamic_cast<isa8_device *>(isadev)->add_slot(tag());
+ dynamic_cast<isa8_device &>(*m_isa_bus).add_slot(tag());
}
diff --git a/src/devices/bus/isa/isa.h b/src/devices/bus/isa/isa.h
index afb94068aec..4a8f4a21e7d 100644
--- a/src/devices/bus/isa/isa.h
+++ b/src/devices/bus/isa/isa.h
@@ -82,7 +82,7 @@
#define MCFG_ISA8_SLOT_ADD(_isatag, _tag, _slot_intf, _def_slot, _fixed) \
MCFG_DEVICE_ADD(_tag, ISA8_SLOT, 0) \
MCFG_DEVICE_SLOT_INTERFACE(_slot_intf, _def_slot, _fixed) \
- downcast<isa8_slot_device &>(*device).set_isa8_slot(this, _isatag);
+ downcast<isa8_slot_device &>(*device).set_isa8_slot(_isatag);
#define MCFG_ISA16_CPU(_cputag) \
downcast<isa8_device &>(*device).set_cputag(_cputag);
#define MCFG_ISA16_BUS_CUSTOM_SPACES() \
@@ -90,7 +90,7 @@
#define MCFG_ISA16_SLOT_ADD(_isatag, _tag, _slot_intf, _def_slot, _fixed) \
MCFG_DEVICE_ADD(_tag, ISA16_SLOT, 0) \
MCFG_DEVICE_SLOT_INTERFACE(_slot_intf, _def_slot, _fixed) \
- downcast<isa16_slot_device &>(*device).set_isa16_slot(this, _isatag);
+ downcast<isa16_slot_device &>(*device).set_isa16_slot(_isatag);
#define MCFG_ISA_BUS_IOCHCK(_iochck) \
devcb = &downcast<isa8_device *>(device)->set_iochck_callback(DEVCB_##_iochck);
@@ -168,14 +168,13 @@ public:
virtual void device_start() override;
// inline configuration
- void set_isa8_slot(device_t *owner, const char *isa_tag) { m_owner = owner; m_isa_tag = isa_tag; }
+ void set_isa8_slot(const char *isa_tag) { m_isa_bus.set_tag(isa_tag); }
protected:
isa8_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock);
// configuration
- device_t *m_owner;
- const char *m_isa_tag;
+ required_device<device_t> m_isa_bus;
};
// device type definition
@@ -348,7 +347,7 @@ public:
virtual void device_start() override;
// inline configuration
- void set_isa16_slot(device_t *owner, const char *isa_tag) { m_owner = owner; m_isa_tag = isa_tag; }
+ void set_isa16_slot(const char *isa_tag) { m_isa_bus.set_tag(isa_tag); }
};
diff --git a/src/devices/bus/macpds/pds_tpdfpd.cpp b/src/devices/bus/macpds/pds_tpdfpd.cpp
index 8fd357afdc1..aba55746cc2 100644
--- a/src/devices/bus/macpds/pds_tpdfpd.cpp
+++ b/src/devices/bus/macpds/pds_tpdfpd.cpp
@@ -92,10 +92,9 @@ macpds_sedisplay_device::macpds_sedisplay_device(const machine_config &mconfig,
device_t(mconfig, type, tag, owner, clock),
device_video_interface(mconfig, *this),
device_macpds_card_interface(mconfig, *this),
- m_vram(nullptr), m_vbl_disable(0), m_count(0), m_clutoffs(0), m_timer(nullptr),
- m_assembled_tag(util::string_format("%s:%s", tag, SEDISPLAY_SCREEN_NAME))
+ m_vram(nullptr), m_vbl_disable(0), m_count(0), m_clutoffs(0), m_timer(nullptr)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, SEDISPLAY_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/macpds/pds_tpdfpd.h b/src/devices/bus/macpds/pds_tpdfpd.h
index 6f1b3c0ab12..21f53e63d7c 100644
--- a/src/devices/bus/macpds/pds_tpdfpd.h
+++ b/src/devices/bus/macpds/pds_tpdfpd.h
@@ -46,7 +46,6 @@ private:
uint32_t m_vbl_disable;
uint32_t m_palette[256], m_colors[3], m_count, m_clutoffs;
emu_timer *m_timer;
- const std::string m_assembled_tag;
};
diff --git a/src/devices/bus/msx_slot/bunsetsu.h b/src/devices/bus/msx_slot/bunsetsu.h
index da26e5350fb..70649340824 100644
--- a/src/devices/bus/msx_slot/bunsetsu.h
+++ b/src/devices/bus/msx_slot/bunsetsu.h
@@ -14,8 +14,8 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_BUNSETSU, msx_slot_bunsetsu_device)
#define MCFG_MSX_SLOT_BUNSETSU_ADD(_tag, _startpage, _numpages, _region, _offset, _bunsetsu_region_tag) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_BUNSETSU, _startpage, _numpages) \
- downcast<msx_slot_rom_device &>(*device).set_rom_start("^" _region, _offset); \
- downcast<msx_slot_bunsetsu_device &>(*device).set_bunsetsu_region_tag("^" _bunsetsu_region_tag);
+ downcast<msx_slot_rom_device &>(*device).set_rom_start(_region, _offset); \
+ downcast<msx_slot_bunsetsu_device &>(*device).set_bunsetsu_region_tag(_bunsetsu_region_tag);
class msx_slot_bunsetsu_device : public msx_slot_rom_device
{
diff --git a/src/devices/bus/msx_slot/disk.h b/src/devices/bus/msx_slot/disk.h
index 698b49b9764..d619cb1aa25 100644
--- a/src/devices/bus/msx_slot/disk.h
+++ b/src/devices/bus/msx_slot/disk.h
@@ -29,35 +29,35 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_DISK6, msx_slot_disk6_device)
#define MCFG_MSX_SLOT_DISK1_ADD(_tag, _startpage, _numpages, _region, _offset, _fdc_tag, _floppy0_tag, _floppy1_tag) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_DISK1, _startpage, _numpages) \
- downcast<msx_slot_rom_device &>(*device).set_rom_start("^" _region, _offset); \
+ downcast<msx_slot_rom_device &>(*device).set_rom_start(_region, _offset); \
downcast<msx_slot_disk_device &>(*device).set_fdc_tag(_fdc_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy0_tag(_floppy0_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy1_tag(_floppy1_tag);
#define MCFG_MSX_SLOT_DISK2_ADD(_tag, _startpage, _numpages, _region, _offset, _fdc_tag, _floppy0_tag, _floppy1_tag) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_DISK2, _startpage, _numpages) \
- downcast<msx_slot_rom_device &>(*device).set_rom_start("^" _region, _offset); \
+ downcast<msx_slot_rom_device &>(*device).set_rom_start(_region, _offset); \
downcast<msx_slot_disk_device &>(*device).set_fdc_tag(_fdc_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy0_tag(_floppy0_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy1_tag(_floppy1_tag);
#define MCFG_MSX_SLOT_DISK3_ADD(_tag, _startpage, _numpages, _region, _offset, _fdc_tag, _floppy0_tag, _floppy1_tag) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_DISK3, _startpage, _numpages) \
- downcast<msx_slot_rom_device &>(*device).set_rom_start("^" _region, _offset); \
+ downcast<msx_slot_rom_device &>(*device).set_rom_start(_region, _offset); \
downcast<msx_slot_disk_device &>(*device).set_fdc_tag(_fdc_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy0_tag(_floppy0_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy1_tag(_floppy1_tag);
#define MCFG_MSX_SLOT_DISK4_ADD(_tag, _startpage, _numpages, _region, _offset, _fdc_tag, _floppy0_tag, _floppy1_tag) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_DISK4, _startpage, _numpages) \
- downcast<msx_slot_rom_device &>(*device).set_rom_start("^" _region, _offset); \
+ downcast<msx_slot_rom_device &>(*device).set_rom_start(_region, _offset); \
downcast<msx_slot_disk_device &>(*device).set_fdc_tag(_fdc_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy0_tag(_floppy0_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy1_tag(_floppy1_tag);
#define MCFG_MSX_SLOT_DISK5_ADD(_tag, _startpage, _numpages, _region, _offset, _fdc_tag, _floppy0_tag, _floppy1_tag, _floppy2_tag, _floppy3_tag) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_DISK5, _startpage, _numpages) \
- downcast<msx_slot_rom_device &>(*device).set_rom_start("^" _region, _offset); \
+ downcast<msx_slot_rom_device &>(*device).set_rom_start(_region, _offset); \
downcast<msx_slot_disk_device &>(*device).set_fdc_tag(_fdc_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy0_tag(_floppy0_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy1_tag(_floppy1_tag); \
@@ -66,7 +66,7 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_DISK6, msx_slot_disk6_device)
#define MCFG_MSX_SLOT_DISK6_ADD(_tag, _startpage, _numpages, _region, _offset, _fdc_tag, _floppy0_tag, _floppy1_tag) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_DISK6, _startpage, _numpages) \
- downcast<msx_slot_rom_device &>(*device).set_rom_start("^" _region, _offset); \
+ downcast<msx_slot_rom_device &>(*device).set_rom_start(_region, _offset); \
downcast<msx_slot_disk_device &>(*device).set_fdc_tag(_fdc_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy0_tag(_floppy0_tag); \
downcast<msx_slot_disk_device &>(*device).set_floppy1_tag(_floppy1_tag);
diff --git a/src/devices/bus/msx_slot/fs4600.h b/src/devices/bus/msx_slot/fs4600.h
index b342b07f3fb..c92bd7a3a1f 100644
--- a/src/devices/bus/msx_slot/fs4600.h
+++ b/src/devices/bus/msx_slot/fs4600.h
@@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_FS4600, msx_slot_fs4600_device)
#define MCFG_MSX_SLOT_FS4600_ADD(_tag, _startpage, _numpages, _region, _offset) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_FS4600, _startpage, _numpages) \
- downcast<msx_slot_fs4600_device &>(*device).set_rom_start("^" _region, _offset);
+ downcast<msx_slot_fs4600_device &>(*device).set_rom_start(_region, _offset);
class msx_slot_fs4600_device : public device_t, public msx_internal_slot_interface
{
diff --git a/src/devices/bus/msx_slot/music.h b/src/devices/bus/msx_slot/music.h
index 3e8b54686c9..ae2ddc979d0 100644
--- a/src/devices/bus/msx_slot/music.h
+++ b/src/devices/bus/msx_slot/music.h
@@ -15,7 +15,7 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_MUSIC, msx_slot_music_device)
#define MCFG_MSX_SLOT_MUSIC_ADD(_tag, _startpage, _numpages, _region, _offset, _ym2413_tag) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_MUSIC, _startpage, _numpages) \
- downcast<msx_slot_rom_device &>(*device).set_rom_start("^" _region, _offset); \
+ downcast<msx_slot_rom_device &>(*device).set_rom_start(_region, _offset); \
downcast<msx_slot_music_device &>(*device).set_ym2413_tag(_ym2413_tag);
class msx_slot_music_device : public msx_slot_rom_device
diff --git a/src/devices/bus/msx_slot/panasonic08.h b/src/devices/bus/msx_slot/panasonic08.h
index 7b4f62429f5..33da0b6620b 100644
--- a/src/devices/bus/msx_slot/panasonic08.h
+++ b/src/devices/bus/msx_slot/panasonic08.h
@@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_PANASONIC08, msx_slot_panasonic08_device)
#define MCFG_MSX_SLOT_PANASONIC08_ADD(_tag, _startpage, _numpages, _region, _offset) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_PANASONIC08, _startpage, _numpages) \
- downcast<msx_slot_panasonic08_device &>(*device).set_rom_start("^" _region, _offset);
+ downcast<msx_slot_panasonic08_device &>(*device).set_rom_start(_region, _offset);
class msx_slot_panasonic08_device : public device_t, public msx_internal_slot_interface
{
diff --git a/src/devices/bus/msx_slot/rom.h b/src/devices/bus/msx_slot/rom.h
index f2f84bd8589..eee554a362a 100644
--- a/src/devices/bus/msx_slot/rom.h
+++ b/src/devices/bus/msx_slot/rom.h
@@ -9,7 +9,7 @@
#define MCFG_MSX_SLOT_ROM_ADD(_tag, _startpage, _numpages, _region, _offset) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_ROM, _startpage, _numpages) \
- downcast<msx_slot_rom_device &>(*device).set_rom_start("^" _region, _offset);
+ downcast<msx_slot_rom_device &>(*device).set_rom_start(_region, _offset);
class msx_slot_rom_device : public device_t,
public msx_internal_slot_interface
diff --git a/src/devices/bus/msx_slot/sony08.h b/src/devices/bus/msx_slot/sony08.h
index c9df3701938..8dfd0297951 100644
--- a/src/devices/bus/msx_slot/sony08.h
+++ b/src/devices/bus/msx_slot/sony08.h
@@ -14,10 +14,9 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_SONY08, msx_slot_sony08_device)
#define MCFG_MSX_SLOT_SONY08_ADD(_tag, _startpage, _numpages, _region, _offset) \
MCFG_MSX_INTERNAL_SLOT_ADD(_tag, MSX_SLOT_SONY08, _startpage, _numpages) \
- downcast<msx_slot_sony08_device &>(*device).set_rom_start("^" _region, _offset);
+ downcast<msx_slot_sony08_device &>(*device).set_rom_start(_region, _offset);
-class msx_slot_sony08_device : public device_t,
- public msx_internal_slot_interface
+class msx_slot_sony08_device : public device_t, public msx_internal_slot_interface
{
public:
msx_slot_sony08_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
diff --git a/src/devices/bus/nubus/nubus_48gc.cpp b/src/devices/bus/nubus/nubus_48gc.cpp
index 0b32fc9dea4..e089e1986db 100644
--- a/src/devices/bus/nubus/nubus_48gc.cpp
+++ b/src/devices/bus/nubus/nubus_48gc.cpp
@@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(NUBUS_824GC, nubus_824gc_device, "nb_824gc", "Apple 8*24 vide
//-------------------------------------------------
MACHINE_CONFIG_START(jmfb_device::device_add_mconfig)
- MCFG_SCREEN_ADD( GC48_SCREEN_NAME, RASTER)
+ MCFG_SCREEN_ADD(GC48_SCREEN_NAME, RASTER)
MCFG_SCREEN_UPDATE_DEVICE(DEVICE_SELF, jmfb_device, screen_update)
MCFG_SCREEN_RAW_PARAMS(25175000, 800, 0, 640, 525, 0, 480)
// MCFG_SCREEN_SIZE(1152, 870)
@@ -76,10 +76,9 @@ jmfb_device::jmfb_device(const machine_config &mconfig, device_type type, const
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
m_screen(nullptr), m_timer(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_stride(0), m_base(0), m_count(0), m_clutoffs(0), m_xres(0), m_yres(0),
- m_is824(is824),
- m_assembled_tag(util::string_format("%s:%s", tag, GC48_SCREEN_NAME))
+ m_is824(is824)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, GC48_SCREEN_NAME);
}
nubus_48gc_device::nubus_48gc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
diff --git a/src/devices/bus/nubus/nubus_48gc.h b/src/devices/bus/nubus/nubus_48gc.h
index 0dbebbf4dcb..3c73befdaea 100644
--- a/src/devices/bus/nubus/nubus_48gc.h
+++ b/src/devices/bus/nubus/nubus_48gc.h
@@ -46,7 +46,6 @@ private:
uint32_t m_registers[0x100];
int m_xres, m_yres;
const bool m_is824;
- const std::string m_assembled_tag;
};
class nubus_48gc_device : public jmfb_device
diff --git a/src/devices/bus/nubus/nubus_m2hires.cpp b/src/devices/bus/nubus/nubus_m2hires.cpp
index f7830f2f47a..6ac472eeb5b 100644
--- a/src/devices/bus/nubus/nubus_m2hires.cpp
+++ b/src/devices/bus/nubus/nubus_m2hires.cpp
@@ -70,10 +70,9 @@ nubus_m2hires_device::nubus_m2hires_device(const machine_config &mconfig, device
device_t(mconfig, type, tag, owner, clock),
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
- m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr),
- m_assembled_tag(util::string_format("%s:%s", tag, M2HIRES_SCREEN_NAME))
+ m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, M2HIRES_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/nubus/nubus_m2hires.h b/src/devices/bus/nubus/nubus_m2hires.h
index 79bd30141c8..339cf8ed00f 100644
--- a/src/devices/bus/nubus/nubus_m2hires.h
+++ b/src/devices/bus/nubus/nubus_m2hires.h
@@ -47,7 +47,6 @@ private:
uint32_t m_mode, m_vbl_disable, m_toggle;
uint32_t m_palette[256], m_colors[3], m_count, m_clutoffs;
emu_timer *m_timer;
- const std::string m_assembled_tag;
};
// device type definition
diff --git a/src/devices/bus/nubus/nubus_m2video.cpp b/src/devices/bus/nubus/nubus_m2video.cpp
index 45fa1e8d129..d7eea8cf22e 100644
--- a/src/devices/bus/nubus/nubus_m2video.cpp
+++ b/src/devices/bus/nubus/nubus_m2video.cpp
@@ -72,10 +72,9 @@ nubus_m2video_device::nubus_m2video_device(const machine_config &mconfig, device
device_t(mconfig, type, tag, owner, clock),
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
- m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr),
- m_assembled_tag(util::string_format("%s:%s", tag, M2VIDEO_SCREEN_NAME))
+ m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, M2VIDEO_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/nubus/nubus_m2video.h b/src/devices/bus/nubus/nubus_m2video.h
index 30344b3d2d0..4c4716cdd4f 100644
--- a/src/devices/bus/nubus/nubus_m2video.h
+++ b/src/devices/bus/nubus/nubus_m2video.h
@@ -47,7 +47,6 @@ private:
uint32_t m_mode, m_vbl_disable, m_toggle;
uint32_t m_palette[256], m_colors[3], m_count, m_clutoffs;
emu_timer *m_timer;
- const std::string m_assembled_tag;
};
diff --git a/src/devices/bus/nubus/nubus_radiustpd.cpp b/src/devices/bus/nubus/nubus_radiustpd.cpp
index 32e66083ae7..98a3ab3e514 100644
--- a/src/devices/bus/nubus/nubus_radiustpd.cpp
+++ b/src/devices/bus/nubus/nubus_radiustpd.cpp
@@ -73,10 +73,9 @@ nubus_radiustpd_device::nubus_radiustpd_device(const machine_config &mconfig, de
device_t(mconfig, type, tag, owner, clock),
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
- m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr),
- m_assembled_tag(util::string_format("%s:%s", tag, RADIUSTPD_SCREEN_NAME))
+ m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, RADIUSTPD_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/nubus/nubus_radiustpd.h b/src/devices/bus/nubus/nubus_radiustpd.h
index d5a3606be20..20400277f1a 100644
--- a/src/devices/bus/nubus/nubus_radiustpd.h
+++ b/src/devices/bus/nubus/nubus_radiustpd.h
@@ -47,7 +47,6 @@ private:
uint32_t m_mode, m_vbl_disable, m_toggle;
uint32_t m_palette[256], m_colors[3], m_count, m_clutoffs;
emu_timer *m_timer;
- const std::string m_assembled_tag;
};
diff --git a/src/devices/bus/nubus/nubus_spec8.cpp b/src/devices/bus/nubus/nubus_spec8.cpp
index 82d7553bc68..d3d45d9b076 100644
--- a/src/devices/bus/nubus/nubus_spec8.cpp
+++ b/src/devices/bus/nubus/nubus_spec8.cpp
@@ -75,10 +75,9 @@ nubus_spec8s3_device::nubus_spec8s3_device(const machine_config &mconfig, device
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_count(0), m_clutoffs(0), m_timer(nullptr),
- m_assembled_tag(util::string_format("%s:%s", tag, SPEC8S3_SCREEN_NAME)),
m_vbl_pending(false), m_parameter(0)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, SPEC8S3_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/nubus/nubus_spec8.h b/src/devices/bus/nubus/nubus_spec8.h
index 07a1639c1fc..41cb94432d1 100644
--- a/src/devices/bus/nubus/nubus_spec8.h
+++ b/src/devices/bus/nubus/nubus_spec8.h
@@ -47,7 +47,6 @@ private:
uint32_t m_mode, m_vbl_disable;
uint32_t m_palette[256], m_colors[3], m_count, m_clutoffs;
emu_timer *m_timer;
- const std::string m_assembled_tag;
//uint32_t m_7xxxxx_regs[0x100000/4];
//int m_width, m_height, m_patofsx, m_patofsy;
diff --git a/src/devices/bus/nubus/nubus_specpdq.cpp b/src/devices/bus/nubus/nubus_specpdq.cpp
index 9eda2555e87..d9e463e7fbf 100644
--- a/src/devices/bus/nubus/nubus_specpdq.cpp
+++ b/src/devices/bus/nubus/nubus_specpdq.cpp
@@ -88,11 +88,10 @@ nubus_specpdq_device::nubus_specpdq_device(const machine_config &mconfig, device
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_count(0), m_clutoffs(0), m_timer(nullptr),
- m_assembled_tag(util::string_format("%s:%s", tag, SPECPDQ_SCREEN_NAME)),
m_width(0), m_height(0), m_patofsx(0), m_patofsy(0), m_vram_addr(0), m_vram_src(0),
m_palette(*this, "palette")
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, SPECPDQ_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/nubus/nubus_specpdq.h b/src/devices/bus/nubus/nubus_specpdq.h
index 88cde4d4a3c..0d976364680 100644
--- a/src/devices/bus/nubus/nubus_specpdq.h
+++ b/src/devices/bus/nubus/nubus_specpdq.h
@@ -47,7 +47,6 @@ private:
uint32_t m_mode, m_vbl_disable;
uint32_t m_palette_val[256], m_colors[3], m_count, m_clutoffs;
emu_timer *m_timer;
- const std::string m_assembled_tag;
uint32_t m_7xxxxx_regs[0x100000/4];
int m_width, m_height, m_patofsx, m_patofsy;
diff --git a/src/devices/bus/nubus/nubus_wsportrait.cpp b/src/devices/bus/nubus/nubus_wsportrait.cpp
index a88c1cbdb9a..19c25347738 100644
--- a/src/devices/bus/nubus/nubus_wsportrait.cpp
+++ b/src/devices/bus/nubus/nubus_wsportrait.cpp
@@ -73,10 +73,9 @@ nubus_wsportrait_device::nubus_wsportrait_device(const machine_config &mconfig,
device_t(mconfig, type, tag, owner, clock),
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
- m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr),
- m_assembled_tag(util::string_format("%s:%s", tag, WSPORTRAIT_SCREEN_NAME))
+ m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, WSPORTRAIT_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/nubus/nubus_wsportrait.h b/src/devices/bus/nubus/nubus_wsportrait.h
index abbdb95b69a..d9614a76eb7 100644
--- a/src/devices/bus/nubus/nubus_wsportrait.h
+++ b/src/devices/bus/nubus/nubus_wsportrait.h
@@ -47,7 +47,6 @@ private:
uint32_t m_mode, m_vbl_disable, m_toggle;
uint32_t m_palette[256], m_colors[3], m_count, m_clutoffs;
emu_timer *m_timer;
- const std::string m_assembled_tag;
};
diff --git a/src/devices/bus/nubus/pds30_30hr.cpp b/src/devices/bus/nubus/pds30_30hr.cpp
index 4efd30712ef..8888c50b5fa 100644
--- a/src/devices/bus/nubus/pds30_30hr.cpp
+++ b/src/devices/bus/nubus/pds30_30hr.cpp
@@ -73,10 +73,9 @@ nubus_xceed30hr_device::nubus_xceed30hr_device(const machine_config &mconfig, de
device_t(mconfig, type, tag, owner, clock),
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
- m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr),
- m_assembled_tag(util::string_format("%s:%s", tag, XCEED30HR_SCREEN_NAME))
+ m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, XCEED30HR_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/nubus/pds30_30hr.h b/src/devices/bus/nubus/pds30_30hr.h
index 7d80ad9a1ec..6249f016205 100644
--- a/src/devices/bus/nubus/pds30_30hr.h
+++ b/src/devices/bus/nubus/pds30_30hr.h
@@ -47,7 +47,6 @@ private:
uint32_t m_mode, m_vbl_disable, m_toggle;
uint32_t m_palette[256], m_colors[3], m_count, m_clutoffs;
emu_timer *m_timer;
- const std::string m_assembled_tag;
};
diff --git a/src/devices/bus/nubus/pds30_cb264.cpp b/src/devices/bus/nubus/pds30_cb264.cpp
index 37846d2f1eb..6ec398a5257 100644
--- a/src/devices/bus/nubus/pds30_cb264.cpp
+++ b/src/devices/bus/nubus/pds30_cb264.cpp
@@ -67,10 +67,9 @@ nubus_cb264se30_device::nubus_cb264se30_device(const machine_config &mconfig, de
device_t(mconfig, type, tag, owner, clock),
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
- m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr),
- m_assembled_tag(util::string_format("%s:%s", tag, CB264SE30_SCREEN_NAME))
+ m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, CB264SE30_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/nubus/pds30_cb264.h b/src/devices/bus/nubus/pds30_cb264.h
index a87f3738a0b..f32289fb0af 100644
--- a/src/devices/bus/nubus/pds30_cb264.h
+++ b/src/devices/bus/nubus/pds30_cb264.h
@@ -47,7 +47,6 @@ private:
uint32_t m_mode, m_vbl_disable, m_toggle;
uint32_t m_palette[256], m_colors[3], m_count, m_clutoffs;
emu_timer *m_timer;
- const std::string m_assembled_tag;
};
diff --git a/src/devices/bus/nubus/pds30_mc30.cpp b/src/devices/bus/nubus/pds30_mc30.cpp
index 592474b3c94..a314b7f9981 100644
--- a/src/devices/bus/nubus/pds30_mc30.cpp
+++ b/src/devices/bus/nubus/pds30_mc30.cpp
@@ -69,10 +69,9 @@ nubus_xceedmc30_device::nubus_xceedmc30_device(const machine_config &mconfig, de
device_t(mconfig, type, tag, owner, clock),
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
- m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr),
- m_assembled_tag(util::string_format("%s:%s", tag, XCEEDMC30_SCREEN_NAME))
+ m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, XCEEDMC30_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/nubus/pds30_mc30.h b/src/devices/bus/nubus/pds30_mc30.h
index 9f120889235..db4fe782753 100644
--- a/src/devices/bus/nubus/pds30_mc30.h
+++ b/src/devices/bus/nubus/pds30_mc30.h
@@ -47,7 +47,6 @@ private:
uint32_t m_mode, m_vbl_disable, m_toggle;
uint32_t m_palette[256], m_colors[3], m_count, m_clutoffs;
emu_timer *m_timer;
- const std::string m_assembled_tag;
};
diff --git a/src/devices/bus/nubus/pds30_procolor816.cpp b/src/devices/bus/nubus/pds30_procolor816.cpp
index 72f1a5afad8..db1c02fea31 100644
--- a/src/devices/bus/nubus/pds30_procolor816.cpp
+++ b/src/devices/bus/nubus/pds30_procolor816.cpp
@@ -72,10 +72,9 @@ nubus_procolor816_device::nubus_procolor816_device(const machine_config &mconfig
device_t(mconfig, type, tag, owner, clock),
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
- m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr),
- m_assembled_tag(util::string_format("%s:%s", tag, PROCOLOR816_SCREEN_NAME))
+ m_vram32(nullptr), m_mode(0), m_vbl_disable(0), m_toggle(0), m_count(0), m_clutoffs(0), m_timer(nullptr)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, PROCOLOR816_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/nubus/pds30_procolor816.h b/src/devices/bus/nubus/pds30_procolor816.h
index 69c0c59e40a..dee825d4096 100644
--- a/src/devices/bus/nubus/pds30_procolor816.h
+++ b/src/devices/bus/nubus/pds30_procolor816.h
@@ -47,7 +47,6 @@ private:
uint32_t m_mode, m_vbl_disable, m_toggle;
uint32_t m_palette[256], m_colors[3], m_count, m_clutoffs;
emu_timer *m_timer;
- const std::string m_assembled_tag;
};
diff --git a/src/devices/bus/nubus/pds30_sigmalview.cpp b/src/devices/bus/nubus/pds30_sigmalview.cpp
index 0630e853748..ea05362d8ea 100644
--- a/src/devices/bus/nubus/pds30_sigmalview.cpp
+++ b/src/devices/bus/nubus/pds30_sigmalview.cpp
@@ -67,10 +67,9 @@ nubus_lview_device::nubus_lview_device(const machine_config &mconfig, device_typ
device_t(mconfig, type, tag, owner, clock),
device_video_interface(mconfig, *this),
device_nubus_card_interface(mconfig, *this),
- m_vram32(nullptr), m_vbl_disable(0), m_toggle(0), m_timer(nullptr), m_protstate(0),
- m_assembled_tag(util::string_format("%s:%s", tag, LVIEW_SCREEN_NAME))
+ m_vram32(nullptr), m_vbl_disable(0), m_toggle(0), m_timer(nullptr), m_protstate(0)
{
- set_screen(m_assembled_tag.c_str());
+ set_screen(*this, LVIEW_SCREEN_NAME);
}
//-------------------------------------------------
diff --git a/src/devices/bus/nubus/pds30_sigmalview.h b/src/devices/bus/nubus/pds30_sigmalview.h
index 26fe4f02348..66cfd175b42 100644
--- a/src/devices/bus/nubus/pds30_sigmalview.h
+++ b/src/devices/bus/nubus/pds30_sigmalview.h
@@ -48,7 +48,6 @@ private:
uint32_t m_palette[256];
emu_timer *m_timer;
int m_protstate;
- const std::string m_assembled_tag;
};
diff --git a/src/devices/bus/sms_ctrl/lphaser.cpp b/src/devices/bus/sms_ctrl/lphaser.cpp
index 467b9ba3056..fb20fc8f70c 100644
--- a/src/devices/bus/sms_ctrl/lphaser.cpp
+++ b/src/devices/bus/sms_ctrl/lphaser.cpp
@@ -93,7 +93,7 @@ sms_light_phaser_device::sms_light_phaser_device(const machine_config &mconfig,
{
// Workaround for failed validation that occurs when running on a driver
// with Sega Scope emulation, which adds 2 screens (left/right lenses).
- set_screen(":screen");
+ set_screen(*this, ":screen");
}
diff --git a/src/devices/cpu/avr8/avr8.h b/src/devices/cpu/avr8/avr8.h
index 973eb9774ec..402cf76dd12 100644
--- a/src/devices/cpu/avr8/avr8.h
+++ b/src/devices/cpu/avr8/avr8.h
@@ -64,7 +64,7 @@
//**************************************************************************
#define MCFG_CPU_AVR8_EEPROM(_tag) \
- downcast<avr8_device &>(*device).set_eeprom_tag("^" _tag);
+ downcast<avr8_device &>(*device).set_eeprom_tag(_tag);
//**************************************************************************
diff --git a/src/devices/cpu/esrip/esrip.h b/src/devices/cpu/esrip/esrip.h
index 1b3f2322042..1c13848d40d 100644
--- a/src/devices/cpu/esrip/esrip.h
+++ b/src/devices/cpu/esrip/esrip.h
@@ -35,7 +35,7 @@
downcast<esrip_device &>(*device).lbrm_prom(_tag);
#define MCFG_ESRIP_SCREEN(screen_tag) \
- downcast<esrip_device &>(*device).set_screen_tag(("^" screen_tag));
+ downcast<esrip_device &>(*device).set_screen_tag(screen_tag);
//**************************************************************************
// TYPE DEFINITIONS
diff --git a/src/devices/machine/genpc.h b/src/devices/machine/genpc.h
index 1c94244e6ff..9408b1bde9c 100644
--- a/src/devices/machine/genpc.h
+++ b/src/devices/machine/genpc.h
@@ -25,8 +25,8 @@
#define MCFG_IBM5160_MOTHERBOARD_ADD(_tag, _cputag) \
MCFG_DEVICE_ADD(_tag, IBM5160_MOTHERBOARD, 0) \
- downcast<ibm5160_mb_device &>(*device).set_cputag("^" _cputag); \
- (*device->subdevice<isa8_device>("isa")).set_cputag("^^" _cputag);
+ downcast<ibm5160_mb_device &>(*device).set_cputag(_cputag); \
+ (*device->subdevice<isa8_device>("isa")).set_cputag(_cputag);
// ======================> ibm5160_mb_device
class ibm5160_mb_device : public device_t
@@ -130,8 +130,8 @@ DECLARE_DEVICE_TYPE(IBM5160_MOTHERBOARD, ibm5160_mb_device)
#define MCFG_IBM5150_MOTHERBOARD_ADD(_tag, _cputag) \
MCFG_DEVICE_ADD(_tag, IBM5150_MOTHERBOARD, 0) \
- downcast<ibm5150_mb_device &>(*device).set_cputag("^" _cputag); \
- (*device->subdevice<isa8_device>("isa")).set_cputag("^^" _cputag);
+ downcast<ibm5150_mb_device &>(*device).set_cputag(_cputag); \
+ (*device->subdevice<isa8_device>("isa")).set_cputag(_cputag);
// ======================> ibm5150_mb_device
class ibm5150_mb_device : public ibm5160_mb_device
@@ -163,8 +163,8 @@ DECLARE_DEVICE_TYPE(IBM5150_MOTHERBOARD, ibm5150_mb_device)
#define MCFG_EC1841_MOTHERBOARD_ADD(_tag, _cputag) \
MCFG_DEVICE_ADD(_tag, EC1841_MOTHERBOARD, 0) \
- downcast<ec1841_mb_device &>(*device).set_cputag("^" _cputag); \
- (*device->subdevice<isa8_device>("isa")).set_cputag("^^" _cputag);
+ downcast<ec1841_mb_device &>(*device).set_cputag(_cputag); \
+ (*device->subdevice<isa8_device>("isa")).set_cputag(_cputag);
class ec1841_mb_device : public ibm5160_mb_device
{
@@ -189,8 +189,8 @@ DECLARE_DEVICE_TYPE(EC1841_MOTHERBOARD, ec1841_mb_device)
#define MCFG_PCNOPPI_MOTHERBOARD_ADD(_tag, _cputag) \
MCFG_DEVICE_ADD(_tag, PCNOPPI_MOTHERBOARD, 0) \
- downcast<pc_noppi_mb_device &>(*device).set_cputag("^" _cputag); \
- (*device->subdevice<isa8_device>("isa")).set_cputag("^^" _cputag);
+ downcast<pc_noppi_mb_device &>(*device).set_cputag(_cputag); \
+ (*device->subdevice<isa8_device>("isa")).set_cputag(_cputag);
class pc_noppi_mb_device : public ibm5160_mb_device
{
diff --git a/src/devices/machine/k033906.h b/src/devices/machine/k033906.h
index 4f46c7f7dc8..58721957cf0 100644
--- a/src/devices/machine/k033906.h
+++ b/src/devices/machine/k033906.h
@@ -19,7 +19,7 @@
***************************************************************************/
#define MCFG_K033906_VOODOO(_tag) \
- downcast<k033906_device &>(*device).set_voodoo_tag("^" _tag);
+ downcast<k033906_device &>(*device).set_voodoo_tag(_tag);
/***************************************************************************
TYPE DEFINITIONS
diff --git a/src/devices/machine/k053252.h b/src/devices/machine/k053252.h
index 917fd5e96d5..7fe29893479 100644
--- a/src/devices/machine/k053252.h
+++ b/src/devices/machine/k053252.h
@@ -29,7 +29,7 @@
downcast<k053252_device &>(*device).set_offsets(_offsx, _offsy);
#define MCFG_K053252_SET_SLAVE_SCREEN(_tag) \
- downcast<k053252_device &>(*device).set_slave_screen("^" _tag);
+ downcast<k053252_device &>(*device).set_slave_screen(_tag);
class k053252_device : public device_t, public device_video_interface
diff --git a/src/devices/machine/k056230.h b/src/devices/machine/k056230.h
index 98f1326541e..ac9d8e905b7 100644
--- a/src/devices/machine/k056230.h
+++ b/src/devices/machine/k056230.h
@@ -19,7 +19,7 @@
***************************************************************************/
#define MCFG_K056230_CPU(_tag) \
- downcast<k056230_device &>(*device).set_cpu_tag("^" _tag);
+ downcast<k056230_device &>(*device).set_cpu_tag(_tag);
#define MCFG_K056230_HACK(_region) \
downcast<k056230_device &>(*device).set_thunderh_hack(_region);
diff --git a/src/devices/machine/laserdsc.h b/src/devices/machine/laserdsc.h
index 157009f865d..34b6c8c2772 100644
--- a/src/devices/machine/laserdsc.h
+++ b/src/devices/machine/laserdsc.h
@@ -77,7 +77,7 @@ enum laserdisc_field_code
#define MCFG_LASERDISC_OVERLAY_SCALE(_scalex, _scaley) \
downcast<laserdisc_device &>(*device).set_overlay_scale(_scalex, _scaley);
#define MCFG_LASERDISC_OVERLAY_PALETTE(_palette_tag) \
- downcast<laserdisc_device &>(*device).set_overlay_palette("^" _palette_tag);
+ downcast<laserdisc_device &>(*device).set_overlay_palette(_palette_tag);
// use these to add laserdisc screens with proper video update parameters
// TODO: actually move these SCREEN_RAW_PARAMS to a common screen info header
diff --git a/src/devices/machine/legscsi.h b/src/devices/machine/legscsi.h
index d00cdd9ef38..b86bb61505c 100644
--- a/src/devices/machine/legscsi.h
+++ b/src/devices/machine/legscsi.h
@@ -8,7 +8,7 @@
#include "bus/scsi/scsihle.h"
#define MCFG_LEGACY_SCSI_PORT(_tag) \
- downcast<legacy_scsi_host_adapter &>(*device).set_scsi_port("^" _tag);
+ downcast<legacy_scsi_host_adapter &>(*device).set_scsi_port(_tag);
class legacy_scsi_host_adapter : public device_t
{
diff --git a/src/devices/machine/mc68328.h b/src/devices/machine/mc68328.h
index 36b756d5fe1..61df82ebe16 100644
--- a/src/devices/machine/mc68328.h
+++ b/src/devices/machine/mc68328.h
@@ -386,7 +386,7 @@ private:
DECLARE_DEVICE_TYPE(MC68328, mc68328_device)
#define MCFG_MC68328_CPU(_tag) \
- downcast<mc68328_device &>(*device).set_cpu_tag("^" _tag);
+ downcast<mc68328_device &>(*device).set_cpu_tag(_tag);
#define MCFG_MC68328_OUT_PORT_A_CB(_devcb) \
devcb = &downcast<mc68328_device &>(*device).set_out_port_a_callback(DEVCB_##_devcb);
diff --git a/src/devices/machine/msm6253.h b/src/devices/machine/msm6253.h
index 8daae35a3c3..a4f9e33efaa 100644
--- a/src/devices/machine/msm6253.h
+++ b/src/devices/machine/msm6253.h
@@ -28,31 +28,31 @@
//**************************************************************************
#define MCFG_MSM6253_IN0_ANALOG_PORT(_input) \
- downcast<msm6253_device &>(*device).set_input_tag(0, "^" _input);
+ downcast<msm6253_device &>(*device).set_input_tag<0>(_input);
#define MCFG_MSM6253_IN1_ANALOG_PORT(_input) \
- downcast<msm6253_device &>(*device).set_input_tag(1, "^" _input);
+ downcast<msm6253_device &>(*device).set_input_tag<1>(_input);
#define MCFG_MSM6253_IN2_ANALOG_PORT(_input) \
- downcast<msm6253_device &>(*device).set_input_tag(2, "^" _input);
+ downcast<msm6253_device &>(*device).set_input_tag<2>(_input);
#define MCFG_MSM6253_IN3_ANALOG_PORT(_input) \
- downcast<msm6253_device &>(*device).set_input_tag(3, "^" _input);
+ downcast<msm6253_device &>(*device).set_input_tag<3>(_input);
#define MCFG_MSM6253_IN0_ANALOG_READ(_class, _method) \
- downcast<msm6253_device &>(*device).set_input_cb(0, msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, this));
+ downcast<msm6253_device &>(*device).set_input_cb<0>(msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, this));
#define MCFG_MSM6253_IN1_ANALOG_READ(_class, _method) \
- downcast<msm6253_device &>(*device).set_input_cb(1, msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, this));
+ downcast<msm6253_device &>(*device).set_input_cb<1>(msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, this));
#define MCFG_MSM6253_IN2_ANALOG_READ(_class, _method) \
- downcast<msm6253_device &>(*device).set_input_cb(2, msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, this));
+ downcast<msm6253_device &>(*device).set_input_cb<2>(msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, this));
#define MCFG_MSM6253_IN3_ANALOG_READ(_class, _method) \
- downcast<msm6253_device &>(*device).set_input_cb(3, msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, this));
+ downcast<msm6253_device &>(*device).set_input_cb<3>(msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, this));
#define MCFG_MSM6253_IN0_ANALOG_DEVREAD(_tag, _class, _method) \
- downcast<msm6253_device &>(*device).set_input_cb(0, msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, _tag));
+ downcast<msm6253_device &>(*device).set_input_cb<0>(msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, _tag));
#define MCFG_MSM6253_IN1_ANALOG_DEVREAD(_tag, _class, _method) \
- downcast<msm6253_device &>(*device).set_input_cb(1, msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, _tag));
+ downcast<msm6253_device &>(*device).set_input_cb<1>(msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, _tag));
#define MCFG_MSM6253_IN2_ANALOG_DEVREAD(_tag, _class, _method) \
- downcast<msm6253_device &>(*device).set_input_cb(2, msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, _tag));
+ downcast<msm6253_device &>(*device).set_input_cb<2>(msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, _tag));
#define MCFG_MSM6253_IN3_ANALOG_DEVREAD(_tag, _class, _method) \
- downcast<msm6253_device &>(*device).set_input_cb(3, msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, _tag));
+ downcast<msm6253_device &>(*device).set_input_cb<3>(msm6253_device::port_read_delegate(&_class::_method, #_class "::" #_method, _tag));
//**************************************************************************
@@ -70,8 +70,8 @@ public:
msm6253_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
// configuration
- void set_input_tag(int port, const char *tag) { m_analog_ports[port].set_tag(tag); }
- template <typename Object> void set_input_cb(int port, Object &&cb) { m_analog_input_cb[port] = std::forward<Object>(cb); }
+ template <unsigned P> void set_input_tag(const char *tag) { m_analog_ports[P].set_tag(tag); }
+ template <unsigned P, typename Object> void set_input_cb(Object &&cb) { m_analog_input_cb[P] = std::forward<Object>(cb); }
// write handlers
WRITE8_MEMBER(address_w);
diff --git a/src/devices/machine/ra17xx.h b/src/devices/machine/ra17xx.h
index c0715336145..4e84a725756 100644
--- a/src/devices/machine/ra17xx.h
+++ b/src/devices/machine/ra17xx.h
@@ -11,10 +11,11 @@
20 ... 2f, 40 ... 4f or 60 ... 6f.
**********************************************************************/
-
#ifndef MAME_MACHINE_RA17XX_H
#define MAME_MACHINE_RA17XX_H
+#pragma once
+
#include "device.h"
#include "cpu/pps4/pps4.h"
@@ -32,7 +33,7 @@
downcast<ra17xx_device &>(*device).set_iowr(DEVCB_##devcb);
#define MCFG_RA17XX_CPU(tag) \
- downcast<ra17xx_device &>(*device).set_cpu_tag("^" tag);
+ downcast<ra17xx_device &>(*device).set_cpu_tag(tag);
class ra17xx_device : public device_t
{
diff --git a/src/devices/machine/s3c2400.h b/src/devices/machine/s3c2400.h
index d4c18ed89ee..11d6c247e62 100644
--- a/src/devices/machine/s3c2400.h
+++ b/src/devices/machine/s3c2400.h
@@ -21,10 +21,10 @@
#define S3C2400_TAG "s3c2400"
#define MCFG_S3C2400_PALETTE(palette_tag) \
- downcast<s3c2400_device &>(*device).set_palette_tag(("^" palette_tag));
+ downcast<s3c2400_device &>(*device).set_palette_tag(palette_tag);
#define MCFG_S3C2400_SCREEN(screen_tag) \
- downcast<s3c2400_device &>(*device).set_screen_tag(("^" screen_tag));
+ downcast<s3c2400_device &>(*device).set_screen_tag(screen_tag);
#define MCFG_S3C2400_CORE_PIN_R_CB(cb) \
devcb = &downcast<s3c2400_device &>(*device).set_core_pin_r_callback(DEVCB_##cb);
diff --git a/src/devices/machine/s3c2410.h b/src/devices/machine/s3c2410.h
index 5df8e0debf3..36ea547f6ca 100644
--- a/src/devices/machine/s3c2410.h
+++ b/src/devices/machine/s3c2410.h
@@ -21,10 +21,10 @@
#define S3C2410_TAG "s3c2410"
#define MCFG_S3C2410_PALETTE(palette_tag) \
- downcast<s3c2410_device &>(*device).set_palette_tag(("^" palette_tag));
+ downcast<s3c2410_device &>(*device).set_palette_tag(palette_tag);
#define MCFG_S3C2410_SCREEN(screen_tag) \
- downcast<s3c2410_device &>(*device).set_screen_tag(("^" screen_tag));
+ downcast<s3c2410_device &>(*device).set_screen_tag(screen_tag);
#define MCFG_S3C2410_CORE_PIN_R_CB(cb) \
devcb = &downcast<s3c2410_device &>(*device).set_core_pin_r_callback(DEVCB_##cb);
diff --git a/src/devices/machine/s3c2440.h b/src/devices/machine/s3c2440.h
index 260f6e4d95a..f226f0bef37 100644
--- a/src/devices/machine/s3c2440.h
+++ b/src/devices/machine/s3c2440.h
@@ -20,10 +20,10 @@
#define S3C2440_TAG "s3c2440"
#define MCFG_S3C2440_PALETTE(_palette_tag) \
- downcast<s3c2440_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<s3c2440_device &>(*device).set_palette_tag(_palette_tag);
#define MCFG_S3C2440_SCREEN(screen_tag) \
- downcast<s3c2440_device &>(*device).set_screen_tag(("^" screen_tag));
+ downcast<s3c2440_device &>(*device).set_screen_tag(screen_tag);
#define MCFG_S3C2440_CORE_PIN_R_CB(_devcb) \
devcb = &downcast<s3c2440_device &>(*device).set_core_pin_r_callback(DEVCB_##_devcb);
diff --git a/src/devices/machine/smpc.h b/src/devices/machine/smpc.h
index abdf526c508..bb18b14da4f 100644
--- a/src/devices/machine/smpc.h
+++ b/src/devices/machine/smpc.h
@@ -24,7 +24,7 @@
MCFG_DEVICE_ADD((tag), SMPC_HLE, (clock))
#define MCFG_SMPC_HLE_SCREEN(screen_tag) \
- downcast<smpc_hle_device &>(*device).set_screen_tag(("^" screen_tag));
+ downcast<smpc_hle_device &>(*device).set_screen_tag(screen_tag);
#define MCFG_SMPC_HLE_CONTROL_PORTS(ctrl1_tag, ctrl2_tag) \
downcast<smpc_hle_device &>(*device).set_control_port_tags(ctrl1_tag, ctrl2_tag);
diff --git a/src/devices/machine/tc009xlvc.h b/src/devices/machine/tc009xlvc.h
index cd6ec859876..17273249baa 100644
--- a/src/devices/machine/tc009xlvc.h
+++ b/src/devices/machine/tc009xlvc.h
@@ -85,6 +85,6 @@ DECLARE_DEVICE_TYPE(TC0091LVC, tc0091lvc_device)
#define MCFG_TC0091LVC_GFXDECODE(gfxtag) \
- downcast<tc0091lvc_device &>(*device).set_gfxdecode_tag(("^" gfxtag));
+ downcast<tc0091lvc_device &>(*device).set_gfxdecode_tag(gfxtag);
#endif // MAME_MACHINE_TL009XLVC_H
diff --git a/src/devices/machine/tmp68301.h b/src/devices/machine/tmp68301.h
index 3034e192b2c..c2d2c9cdbbd 100644
--- a/src/devices/machine/tmp68301.h
+++ b/src/devices/machine/tmp68301.h
@@ -15,7 +15,7 @@
// FIXME: M68000 ought to be a parent class, not an external object
#define MCFG_TMP68301_CPU(_tag) \
- downcast<tmp68301_device &>(*device).set_cpu_tag("^" _tag);
+ downcast<tmp68301_device &>(*device).set_cpu_tag(_tag);
#define MCFG_TMP68301_IN_PARALLEL_CB(cb) \
devcb = &downcast<tmp68301_device &>(*device).set_in_parallel_callback((DEVCB_##cb));
diff --git a/src/devices/machine/upd4701.h b/src/devices/machine/upd4701.h
index a7a09397281..370a7e5a94c 100644
--- a/src/devices/machine/upd4701.h
+++ b/src/devices/machine/upd4701.h
@@ -32,9 +32,9 @@
***************************************************************************/
#define MCFG_UPD4701_PORTX(_tag) \
- downcast<upd4701_device &>(*device).set_portx_tag("^" _tag);
+ downcast<upd4701_device &>(*device).set_portx_tag(_tag);
#define MCFG_UPD4701_PORTY(_tag) \
- downcast<upd4701_device &>(*device).set_porty_tag("^" _tag);
+ downcast<upd4701_device &>(*device).set_porty_tag(_tag);
#define MCFG_UPD4701_CF_CALLBACK(_devcb) \
devcb = downcast<upd4701_device &>(*device).set_cf_cb(DEVCB_##_devcb);
#define MCFG_UPD4701_SF_CALLBACK(_devcb) \
diff --git a/src/devices/machine/upd71071.h b/src/devices/machine/upd71071.h
index 813a5bea3fe..7989d180169 100644
--- a/src/devices/machine/upd71071.h
+++ b/src/devices/machine/upd71071.h
@@ -76,7 +76,7 @@ private:
DECLARE_DEVICE_TYPE(UPD71071, upd71071_device)
#define MCFG_UPD71071_CPU(tag) \
- downcast<upd71071_device &>(*device).set_cpu_tag(("^" tag));
+ downcast<upd71071_device &>(*device).set_cpu_tag(tag);
#define MCFG_UPD71071_CLOCK(clk) \
downcast<upd71071_device &>(*device).set_clock((clk));
diff --git a/src/devices/sound/c6280.h b/src/devices/sound/c6280.h
index 11cae3eaa63..1c5474e3adf 100644
--- a/src/devices/sound/c6280.h
+++ b/src/devices/sound/c6280.h
@@ -57,6 +57,6 @@ private:
DECLARE_DEVICE_TYPE(C6280, c6280_device)
#define MCFG_C6280_CPU(tag) \
- downcast<c6280_device &>(*device).set_devicecpu_tag(("^" tag));
+ downcast<c6280_device &>(*device).set_devicecpu_tag(tag);
#endif // MAME_SOUND_C6280_H
diff --git a/src/devices/sound/es8712.h b/src/devices/sound/es8712.h
index 30665b9fdc3..796167331ed 100644
--- a/src/devices/sound/es8712.h
+++ b/src/devices/sound/es8712.h
@@ -23,7 +23,7 @@
#define MCFG_ES8712_MSM_WRITE_CALLBACK(_devcb) \
devcb = &downcast<es8712_device &>(*device).set_msm_write_callback(DEVCB_##_devcb);
#define MCFG_ES8712_MSM_TAG(_msmtag) \
- downcast<es8712_device &>(*device).set_msm_tag(("^" _msmtag));
+ downcast<es8712_device &>(*device).set_msm_tag(_msmtag);
//**************************************************************************
diff --git a/src/devices/sound/gaelco.h b/src/devices/sound/gaelco.h
index d046ab791c4..f670eaf0c70 100644
--- a/src/devices/sound/gaelco.h
+++ b/src/devices/sound/gaelco.h
@@ -11,7 +11,7 @@
//**************************************************************************
#define MCFG_GAELCO_SND_DATA(_tag) \
- downcast<gaelco_gae1_device &>(*device).set_snd_data_tag("^" _tag);
+ downcast<gaelco_gae1_device &>(*device).set_snd_data_tag(_tag);
#define MCFG_GAELCO_BANKS(_offs1, _offs2, _offs3, _offs4) \
downcast<gaelco_gae1_device &>(*device).set_bank_offsets(_offs1, _offs2, _offs3, _offs4);
diff --git a/src/devices/sound/tms5110.h b/src/devices/sound/tms5110.h
index 01de692eb8d..066590302da 100644
--- a/src/devices/sound/tms5110.h
+++ b/src/devices/sound/tms5110.h
@@ -338,7 +338,7 @@ private:
DECLARE_DEVICE_TYPE(TMSPROM, tmsprom_device)
#define MCFG_TMSPROM_REGION(_region) \
- downcast<tmsprom_device &>(*device).set_region("^" _region);
+ downcast<tmsprom_device &>(*device).set_region(_region);
#define MCFG_TMSPROM_ROM_SIZE(_size) \
downcast<tmsprom_device &>(*device).set_rom_size(_size);
diff --git a/src/devices/video/315_5313.h b/src/devices/video/315_5313.h
index 539fa39e6d6..412e28fb094 100644
--- a/src/devices/video/315_5313.h
+++ b/src/devices/video/315_5313.h
@@ -36,7 +36,7 @@
downcast<sega315_5313_device &>(*device).set_palwrite_base(_data);
#define MCFG_SEGA315_5313_PALETTE(_palette_tag) \
- downcast<sega315_5313_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<sega315_5313_device &>(*device).set_palette_tag(_palette_tag);
// Temporary solution while 32x VDP mixing and scanline interrupting is moved outside MD VDP
diff --git a/src/devices/video/ef9345.h b/src/devices/video/ef9345.h
index f93229c6efa..b6944dcb548 100644
--- a/src/devices/video/ef9345.h
+++ b/src/devices/video/ef9345.h
@@ -15,7 +15,7 @@
#define MCFG_EF9345_PALETTE(_palette_tag) \
- downcast<ef9345_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<ef9345_device &>(*device).set_palette_tag(_palette_tag);
//**************************************************************************
// TYPE DEFINITIONS
diff --git a/src/devices/video/ef9364.h b/src/devices/video/ef9364.h
index cc1faafaac3..2ecf4079e04 100644
--- a/src/devices/video/ef9364.h
+++ b/src/devices/video/ef9364.h
@@ -14,7 +14,7 @@
#pragma once
#define MCFG_EF9364_PALETTE(_palette_tag) \
- downcast<ef9364_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<ef9364_device &>(*device).set_palette_tag(_palette_tag);
#define MCFG_EF9364_PAGES_CNT(_pages_number) \
downcast<ef9364_device &>(*device).set_nb_of_pages(_pages_number);
diff --git a/src/devices/video/ef9365.h b/src/devices/video/ef9365.h
index 5f0bbadd8b1..6ecdeec6d72 100644
--- a/src/devices/video/ef9365.h
+++ b/src/devices/video/ef9365.h
@@ -14,7 +14,7 @@
#pragma once
#define MCFG_EF936X_PALETTE(palette_tag) \
- downcast<ef9365_device &>(*device).set_palette_tag(("^" palette_tag));
+ downcast<ef9365_device &>(*device).set_palette_tag(palette_tag);
#define MCFG_EF936X_BITPLANES_CNT(bitplanes_number) \
downcast<ef9365_device &>(*device).set_nb_bitplanes((bitplanes_number));
diff --git a/src/devices/video/gb_lcd.h b/src/devices/video/gb_lcd.h
index 616b2f3e20c..530788d4de2 100644
--- a/src/devices/video/gb_lcd.h
+++ b/src/devices/video/gb_lcd.h
@@ -295,19 +295,19 @@ DECLARE_DEVICE_TYPE(CGB_PPU, cgb_ppu_device)
#define MCFG_DMG_PPU_ADD(_tag, _cpu_tag ) \
MCFG_DEVICE_ADD( _tag, DMG_PPU, 0 ) \
- downcast<dmg_ppu_device &>(*device).set_lr35902_tag("^" _cpu_tag);
+ downcast<dmg_ppu_device &>(*device).set_lr35902_tag(_cpu_tag);
#define MCFG_MGB_PPU_ADD(_tag, _cpu_tag ) \
MCFG_DEVICE_ADD( _tag, MGB_PPU, 0 ) \
- downcast<dmg_ppu_device &>(*device).set_lr35902_tag("^" _cpu_tag);
+ downcast<dmg_ppu_device &>(*device).set_lr35902_tag(_cpu_tag);
#define MCFG_SGB_PPU_ADD(_tag, _cpu_tag ) \
MCFG_DEVICE_ADD( _tag, SGB_PPU, 0 ) \
- downcast<dmg_ppu_device &>(*device).set_lr35902_tag("^" _cpu_tag);
+ downcast<dmg_ppu_device &>(*device).set_lr35902_tag(_cpu_tag);
#define MCFG_CGB_PPU_ADD(_tag, _cpu_tag ) \
MCFG_DEVICE_ADD( _tag, CGB_PPU, 0 ) \
- downcast<dmg_ppu_device &>(*device).set_lr35902_tag("^" _cpu_tag);
+ downcast<dmg_ppu_device &>(*device).set_lr35902_tag(_cpu_tag);
#endif // MAME_VIDEO_GB_LCD_H
diff --git a/src/devices/video/imagetek_i4100.h b/src/devices/video/imagetek_i4100.h
index e09efb8ebb1..244193cbec3 100644
--- a/src/devices/video/imagetek_i4100.h
+++ b/src/devices/video/imagetek_i4100.h
@@ -19,7 +19,7 @@
//**************************************************************************
#define MCFG_I4100_GFXDECODE(gfxtag) \
- downcast<imagetek_i4100_device &>(*device).set_gfxdecode_tag(("^" gfxtag));
+ downcast<imagetek_i4100_device &>(*device).set_gfxdecode_tag(gfxtag);
#define MCFG_I4100_BLITTER_END_CALLBACK(_devcb) \
devcb = &downcast<imagetek_i4100_device &>(*device).set_blitter_irq_callback(DEVCB_##_devcb);
diff --git a/src/devices/video/mb_vcu.h b/src/devices/video/mb_vcu.h
index c6e1d7b30f9..b6008cea8bd 100644
--- a/src/devices/video/mb_vcu.h
+++ b/src/devices/video/mb_vcu.h
@@ -90,9 +90,9 @@ DECLARE_DEVICE_TYPE(MB_VCU, mb_vcu_device)
//**************************************************************************
#define MCFG_MB_VCU_CPU(_tag) \
- downcast<mb_vcu_device &>(*device).set_cpu_tag("^" _tag);
+ downcast<mb_vcu_device &>(*device).set_cpu_tag(_tag);
#define MCFG_MB_VCU_PALETTE(_palette_tag) \
- downcast<mb_vcu_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<mb_vcu_device &>(*device).set_palette_tag(_palette_tag);
#endif // MAME_VIDEO_MB_VCU_H
diff --git a/src/devices/video/mos6566.h b/src/devices/video/mos6566.h
index 94ab067a425..56e106022db 100644
--- a/src/devices/video/mos6566.h
+++ b/src/devices/video/mos6566.h
@@ -90,7 +90,7 @@
//***************************************************************************
#define MCFG_MOS6566_CPU(_tag) \
- downcast<mos6566_device &>(*device).set_cpu_tag("^" _tag);
+ downcast<mos6566_device &>(*device).set_cpu_tag(_tag);
#define MCFG_MOS6566_IRQ_CALLBACK(_write) \
devcb = &downcast<mos6566_device &>(*device).set_irq_wr_callback(DEVCB_##_write);
diff --git a/src/devices/video/msm6222b.cpp b/src/devices/video/msm6222b.cpp
index 1e342e04084..ebcbfea24fe 100644
--- a/src/devices/video/msm6222b.cpp
+++ b/src/devices/video/msm6222b.cpp
@@ -31,14 +31,14 @@ msm6222b_device::msm6222b_device(const machine_config &mconfig, device_type type
msm6222b_device::msm6222b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
msm6222b_device(mconfig, MSM6222B, tag, owner, clock)
{
- m_cgrom.set_tag(DEVICE_SELF);
+ m_cgrom.set_tag(*this, DEVICE_SELF);
}
msm6222b_01_device::msm6222b_01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
msm6222b_device(mconfig, MSM6222B_01, tag, owner, clock)
{
// load the fixed cgrom
- m_cgrom.set_tag("cgrom");
+ m_cgrom.set_tag(*this, "cgrom");
}
const tiny_rom_entry *msm6222b_01_device::device_rom_region() const
diff --git a/src/devices/video/ppu2c0x.h b/src/devices/video/ppu2c0x.h
index 95c929ccdab..a516cbb5a2a 100644
--- a/src/devices/video/ppu2c0x.h
+++ b/src/devices/video/ppu2c0x.h
@@ -59,7 +59,7 @@
#define MCFG_PPU2C0X_SET_SCREEN MCFG_VIDEO_SET_SCREEN
#define MCFG_PPU2C0X_CPU(_tag) \
- downcast<ppu2c0x_device &>(*device).set_cpu_tag("^" _tag);
+ downcast<ppu2c0x_device &>(*device).set_cpu_tag(_tag);
#define MCFG_PPU2C0X_COLORBASE(_color) \
downcast<ppu2c0x_device &>(*device).set_color_base(_color);
diff --git a/src/devices/video/ramdac.h b/src/devices/video/ramdac.h
index 55471af0431..d6be006ab35 100644
--- a/src/devices/video/ramdac.h
+++ b/src/devices/video/ramdac.h
@@ -20,7 +20,7 @@
#define MCFG_RAMDAC_ADD(_tag, _map, _palette_tag) \
MCFG_DEVICE_ADD(_tag, RAMDAC, 0) \
MCFG_DEVICE_ADDRESS_MAP(0, _map) \
- downcast<ramdac_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<ramdac_device &>(*device).set_palette_tag(_palette_tag);
#define MCFG_RAMDAC_COLOR_BASE(_color_base) \
downcast<ramdac_device &>(*device).set_color_base(_color_base);
diff --git a/src/devices/video/tms9927.h b/src/devices/video/tms9927.h
index 90da2ff414a..9ee746bc522 100644
--- a/src/devices/video/tms9927.h
+++ b/src/devices/video/tms9927.h
@@ -20,7 +20,7 @@
downcast<tms9927_device &>(*device).set_char_width(_pixels);
#define MCFG_TMS9927_REGION(_tag) \
- downcast<tms9927_device &>(*device).set_region_tag("^" _tag);
+ downcast<tms9927_device &>(*device).set_region_tag(_tag);
#define MCFG_TMS9927_OVERSCAN(_left, _right, _top, _bottom) \
downcast<tms9927_device &>(*device).set_overscan(_left, _right, _top, _bottom);
diff --git a/src/devices/video/vic4567.h b/src/devices/video/vic4567.h
index 2b94e93f0cd..5d24654ac21 100644
--- a/src/devices/video/vic4567.h
+++ b/src/devices/video/vic4567.h
@@ -237,7 +237,7 @@ DECLARE_DEVICE_TYPE(VIC3, vic3_device)
#define MCFG_VIC3_CPU(tag) \
- downcast<vic3_device &>(*device).set_cpu_tag(("^" tag));
+ downcast<vic3_device &>(*device).set_cpu_tag(tag);
#define MCFG_VIC3_TYPE(type) \
downcast<vic3_device &>(*device).set_vic3_type((vic3_device::vic3_type::type));
diff --git a/src/emu/devfind.cpp b/src/emu/devfind.cpp
index 81071fa891c..ba2d024a7ca 100644
--- a/src/emu/devfind.cpp
+++ b/src/emu/devfind.cpp
@@ -116,14 +116,25 @@ finder_base::~finder_base()
//-------------------------------------------------
+// set_tag - set tag
+//-------------------------------------------------
+
+void finder_base::set_tag(char const *tag)
+{
+ m_base = m_base.get().mconfig().current_device();
+ m_tag = tag;
+}
+
+
+//-------------------------------------------------
// find_memregion - find memory region
//-------------------------------------------------
void *finder_base::find_memregion(u8 width, size_t &length, bool required) const
{
// look up the region and return nullptr if not found
- memory_region *const region = m_base.memregion(m_tag);
- if (region == nullptr)
+ memory_region *const region(m_base.get().memregion(m_tag));
+ if (!region)
{
length = 0;
return nullptr;
@@ -162,10 +173,10 @@ bool finder_base::validate_memregion(size_t bytes, bool required) const
{
// make sure we can resolve the full path to the region
size_t bytes_found = 0;
- std::string region_fulltag = m_base.subtag(m_tag);
+ std::string const region_fulltag(m_base.get().subtag(m_tag));
// look for the region
- for (device_t const &dev : device_iterator(m_base.mconfig().root_device()))
+ for (device_t const &dev : device_iterator(m_base.get().mconfig().root_device()))
{
for (romload::region const &region : romload::entries(dev.rom_region()).get_regions())
{
@@ -197,8 +208,8 @@ bool finder_base::validate_memregion(size_t bytes, bool required) const
void *finder_base::find_memshare(u8 width, size_t &bytes, bool required) const
{
// look up the share and return nullptr if not found
- memory_share *share = m_base.memshare(m_tag);
- if (share == nullptr)
+ memory_share *const share(m_base.get().memshare(m_tag));
+ if (!share)
return nullptr;
// check the width and warn if not correct
@@ -233,7 +244,7 @@ bool finder_base::report_missing(bool found, const char *objname, bool required)
return true;
// otherwise, report
- std::string const region_fulltag = m_base.subtag(m_tag);
+ std::string const region_fulltag(m_base.get().subtag(m_tag));
if (required)
osd_printf_error("Required %s '%s' not found\n", objname, region_fulltag.c_str());
else
diff --git a/src/emu/devfind.h b/src/emu/devfind.h
index 2ba7303239d..90e7e4f3dba 100644
--- a/src/emu/devfind.h
+++ b/src/emu/devfind.h
@@ -17,6 +17,7 @@
#pragma once
+#include <functional>
#include <iterator>
#include <stdexcept>
#include <type_traits>
@@ -259,10 +260,27 @@ public:
/// Allows search tag to be changed after construction. Note that
/// this must be done before resolution time to take effect. Also
/// note that the tag is not copied.
+ /// \param [in] base Updated search base. The tag must be specified
+ /// relative to this device.
/// \param [in] tag Updated search tag. This is not copied, it is
/// the caller's responsibility to ensure this pointer remains
/// valid until resolution time.
- void set_tag(char const *tag) { m_tag = tag; }
+ void set_tag(device_t &base, char const *tag)
+ {
+ m_base = base;
+ m_tag = tag;
+ }
+
+ /// \brief Set search tag
+ ///
+ /// Allows search tag to be changed after construction. Note that
+ /// this must be done before resolution time to take effect. Also
+ /// note that the tag is not copied.
+ /// \param [in] tag Updated search tag relative to the current
+ /// device being configured. This is not copied, it is the
+ /// caller's responsibility to ensure this pointer remains valid
+ /// until resolution time.
+ void set_tag(char const *tag);
/// \brief Is the object to be resolved before memory maps?
///
@@ -375,7 +393,7 @@ protected:
finder_base *const m_next;
/// \brief Base device to search from
- device_t &m_base;
+ std::reference_wrapper<device_t> m_base;
/// \brief Object tag to search for
char const *m_tag;
@@ -494,7 +512,7 @@ private:
/// is found, false otherwise.
virtual bool findit(bool isvalidation) override
{
- device_t *const device = this->m_base.subdevice(this->m_tag);
+ device_t *const device = this->m_base.get().subdevice(this->m_tag);
this->m_target = dynamic_cast<DeviceClass *>(device);
if (device && !this->m_target)
this->printf_warning("Device '%s' found but is of incorrect type (actual type is %s)\n", this->m_tag, device->name());
@@ -560,7 +578,7 @@ private:
virtual bool findit(bool isvalidation) override
{
if (isvalidation) return this->validate_memregion(0, Required);
- this->m_target = this->m_base.memregion(this->m_tag);
+ this->m_target = this->m_base.get().memregion(this->m_tag);
return this->report_missing("memory region");
}
};
@@ -620,7 +638,7 @@ public:
virtual bool findit(bool isvalidation) override
{
if (isvalidation) return true;
- this->m_target = this->m_base.membank(this->m_tag);
+ this->m_target = this->m_base.get().membank(this->m_tag);
return this->report_missing("memory bank");
}
};
@@ -691,7 +709,7 @@ private:
virtual bool findit(bool isvalidation) override
{
if (isvalidation) return true;
- this->m_target = this->m_base.ioport(this->m_tag);
+ this->m_target = this->m_base.get().ioport(this->m_tag);
return this->report_missing("I/O port");
}
};
@@ -863,7 +881,7 @@ public:
m_allocated.resize(entries);
this->m_target = &m_allocated[0];
m_bytes = entries * sizeof(PointerType);
- this->m_base.save_item(m_allocated, this->m_tag);
+ this->m_base.get().save_item(m_allocated, this->m_tag);
}
private:
diff --git a/src/emu/divideo.cpp b/src/emu/divideo.cpp
index 6a06aa3e857..66cbd6105e9 100644
--- a/src/emu/divideo.cpp
+++ b/src/emu/divideo.cpp
@@ -25,10 +25,11 @@ const char device_video_interface::s_unconfigured_screen_tag[] = "!!UNCONFIGURED
//-------------------------------------------------
device_video_interface::device_video_interface(const machine_config &mconfig, device_t &device, bool screen_required)
- : device_interface(device, "video"),
- m_screen_required(screen_required),
- m_screen_tag(s_unconfigured_screen_tag),
- m_screen(nullptr)
+ : device_interface(device, "video")
+ , m_screen_required(screen_required)
+ , m_screen_base(&device)
+ , m_screen_tag(s_unconfigured_screen_tag)
+ , m_screen(nullptr)
{
}
@@ -42,6 +43,13 @@ device_video_interface::~device_video_interface()
}
+void device_video_interface::set_screen(const char *tag)
+{
+ m_screen_base = &device().mconfig().current_device();
+ m_screen_tag = tag;
+}
+
+
//-------------------------------------------------
// interface_validity_check - validation for a
// device after the configuration has been
@@ -52,19 +60,18 @@ void device_video_interface::interface_validity_check(validity_checker &valid) c
{
// only look up screens if we haven't explicitly requested no screen
screen_device *screen = nullptr;
- if (m_screen_tag != nullptr)
+ if (m_screen_tag)
{
- // find the screen device if explicitly configured
if (strcmp(m_screen_tag, s_unconfigured_screen_tag) != 0)
{
- screen = device().siblingdevice<screen_device>(m_screen_tag);
- if (screen == nullptr)
+ // find the screen device if explicitly configured
+ screen = m_screen_base->subdevice<screen_device>(m_screen_tag);
+ if (!screen)
osd_printf_error("Screen '%s' not found, explicitly set for device '%s'\n", m_screen_tag, device().tag());
}
-
- // otherwise, look for a single match
else
{
+ // otherwise, look for a single match
screen_device_iterator iter(device().mconfig().root_device());
screen = iter.first();
if (iter.count() > 1)
@@ -73,7 +80,7 @@ void device_video_interface::interface_validity_check(validity_checker &valid) c
}
// error if no screen is found
- if (screen == nullptr && m_screen_required)
+ if (!screen && m_screen_required)
osd_printf_error("Device '%s' requires a screen\n", device().tag());
}
@@ -86,19 +93,18 @@ void device_video_interface::interface_validity_check(validity_checker &valid) c
void device_video_interface::interface_pre_start()
{
// only look up screens if we haven't explicitly requested no screen
- if (m_screen_tag != nullptr)
+ if (m_screen_tag)
{
- // find the screen device if explicitly configured
if (strcmp(m_screen_tag, s_unconfigured_screen_tag) != 0)
{
- m_screen = device().siblingdevice<screen_device>(m_screen_tag);
- if (m_screen == nullptr)
+ // find the screen device if explicitly configured
+ m_screen = m_screen_base->subdevice<screen_device>(m_screen_tag);
+ if (!m_screen)
throw emu_fatalerror("Screen '%s' not found, explicitly set for device '%s'", m_screen_tag, device().tag());
}
-
- // otherwise, look for a single match
else
{
+ // otherwise, look for a single match
screen_device_iterator iter(device().machine().root_device());
m_screen = iter.first();
if (iter.count() > 1)
@@ -107,21 +113,19 @@ void device_video_interface::interface_pre_start()
}
// fatal error if no screen is found
- if (m_screen == nullptr && m_screen_required)
+ if (!m_screen)
throw emu_fatalerror("Device '%s' requires a screen", device().tag());
// if we have a screen and it's not started, wait for it
device_palette_interface *palintf;
- if (m_screen != nullptr && !m_screen->started())
+ if (m_screen && !m_screen->started())
{
// avoid circular dependency if we are also a palette device
if (!device().interface(palintf))
throw device_missing_dependencies();
- else
- {
- // no other palette may be specified
- if (m_screen->has_palette() && palintf != &m_screen->palette())
- throw emu_fatalerror("Device '%s' cannot control screen '%s' with palette '%s'", device().tag(), m_screen_tag, m_screen->palette().device().tag());
- }
+
+ // no other palette may be specified
+ if (m_screen->has_palette() && palintf != &m_screen->palette())
+ throw emu_fatalerror("Device '%s' cannot control screen '%s' with palette '%s'", device().tag(), m_screen_tag, m_screen->palette().device().tag());
}
}
diff --git a/src/emu/divideo.h b/src/emu/divideo.h
index 5e2c5d1798d..87425f09a9a 100644
--- a/src/emu/divideo.h
+++ b/src/emu/divideo.h
@@ -43,7 +43,12 @@ public:
virtual ~device_video_interface();
// configuration
- void set_screen(const char *tag) { m_screen_tag = tag; }
+ void set_screen(const char *tag);
+ void set_screen(device_t &base, const char *tag)
+ {
+ m_screen_base = &base;
+ m_screen_tag = tag;
+ }
// getters
screen_device &screen() const { return *m_screen; }
@@ -57,6 +62,7 @@ protected:
private:
// configuration state
bool m_screen_required; // is a screen required?
+ device_t * m_screen_base; // base device for resolving target screen
const char * m_screen_tag; // configured tag for the target screen
// internal state
diff --git a/src/emu/emupal.h b/src/emu/emupal.h
index 467cbc2c818..c16960537f0 100644
--- a/src/emu/emupal.h
+++ b/src/emu/emupal.h
@@ -273,7 +273,7 @@
// other standard palettes
#define MCFG_PALETTE_ADD_RRRRGGGGBBBB_PROMS(_tag, _region, _entries) \
MCFG_PALETTE_ADD(_tag, _entries) \
- downcast<palette_device &>(*device).set_prom_region("^" _region); \
+ downcast<palette_device &>(*device).set_prom_region(_region); \
downcast<palette_device &>(*device).set_init(palette_init_delegate(FUNC(palette_device::palette_init_RRRRGGGGBBBB_proms), downcast<palette_device *>(device)));
// not implemented yet
diff --git a/src/emu/mconfig.h b/src/emu/mconfig.h
index 317acc91309..86902c4b525 100644
--- a/src/emu/mconfig.h
+++ b/src/emu/mconfig.h
@@ -82,7 +82,8 @@ public:
// getters
const game_driver &gamedrv() const { return m_gamedrv; }
- device_t &root_device() const { assert(m_root_device != nullptr); return *m_root_device; }
+ device_t &root_device() const { assert(m_root_device); return *m_root_device; }
+ device_t &current_device() const { assert(m_current_device); return *m_current_device; }
emu_options &options() const { return m_options; }
inline device_t *device(const char *tag) const { return root_device().subdevice(tag); }
template <class DeviceClass> inline DeviceClass *device(const char *tag) const { return downcast<DeviceClass *>(device(tag)); }
diff --git a/src/emu/tilemap.h b/src/emu/tilemap.h
index ae62cdc873b..c37cdd66be0 100644
--- a/src/emu/tilemap.h
+++ b/src/emu/tilemap.h
@@ -370,7 +370,7 @@ enum tilemap_standard_mapper
#define MCFG_TILEMAP_ADD(_tag) \
MCFG_DEVICE_ADD(_tag, TILEMAP, 0)
#define MCFG_TILEMAP_GFXDECODE(_gfxtag) \
- downcast<tilemap_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<tilemap_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_TILEMAP_BYTES_PER_ENTRY(_bpe) \
downcast<tilemap_device &>(*device).set_bytes_per_entry(_bpe);
#define MCFG_TILEMAP_INFO_CB_DRIVER(_class, _method) \
diff --git a/src/mame/audio/namco52.h b/src/mame/audio/namco52.h
index a720ce7b573..97221fb91cb 100644
--- a/src/mame/audio/namco52.h
+++ b/src/mame/audio/namco52.h
@@ -10,7 +10,7 @@
MCFG_DEVICE_ADD(_tag, NAMCO_52XX, _clock)
#define MCFG_NAMCO_52XX_DISCRETE(_tag) \
- downcast<namco_52xx_device &>(*device).set_discrete("^" _tag);
+ downcast<namco_52xx_device &>(*device).set_discrete(_tag);
#define MCFG_NAMCO_52XX_BASENODE(_node) \
downcast<namco_52xx_device &>(*device).set_basenote(_node);
diff --git a/src/mame/audio/namco54.h b/src/mame/audio/namco54.h
index 4bc86b7c221..750950ea462 100644
--- a/src/mame/audio/namco54.h
+++ b/src/mame/audio/namco54.h
@@ -11,7 +11,7 @@
MCFG_DEVICE_ADD(_tag, NAMCO_54XX, _clock)
#define MCFG_NAMCO_54XX_DISCRETE(_tag) \
- downcast<namco_54xx_device &>(*device).set_discrete("^" _tag);
+ downcast<namco_54xx_device &>(*device).set_discrete(_tag);
#define MCFG_NAMCO_54XX_BASENODE(_node) \
downcast<namco_54xx_device &>(*device).set_basenote(_node);
diff --git a/src/mame/audio/seibu.h b/src/mame/audio/seibu.h
index 099f5c004db..4f66ecce37b 100644
--- a/src/mame/audio/seibu.h
+++ b/src/mame/audio/seibu.h
@@ -182,10 +182,10 @@ DECLARE_DEVICE_TYPE(SEIBU_ADPCM, seibu_adpcm_device)
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNUSED )
#define MCFG_SEIBU_SOUND_CPU(_audiocputag) \
- downcast<seibu_sound_device &>(*device).set_cpu_tag("^" _audiocputag);
+ downcast<seibu_sound_device &>(*device).set_cpu_tag(_audiocputag);
#define MCFG_SEIBU_SOUND_ROMBANK(_banktag) \
- downcast<seibu_sound_device &>(*device).set_rombank_tag("^" _banktag);
+ downcast<seibu_sound_device &>(*device).set_rombank_tag(_banktag);
#define MCFG_SEIBU_SOUND_YM_READ_CB(_devcb) \
devcb = &downcast<seibu_sound_device &>(*device).set_ym_read_callback(DEVCB_##_devcb);
diff --git a/src/mame/audio/taitosnd.h b/src/mame/audio/taitosnd.h
index e78ec5ab519..a3dc1f2eaba 100644
--- a/src/mame/audio/taitosnd.h
+++ b/src/mame/audio/taitosnd.h
@@ -9,10 +9,10 @@
//**************************************************************************
#define MCFG_TC0140SYT_MASTER_CPU(_tag) \
- downcast<tc0140syt_device &>(*device).set_master_tag("^" _tag);
+ downcast<tc0140syt_device &>(*device).set_master_tag(_tag);
#define MCFG_TC0140SYT_SLAVE_CPU(_tag) \
- downcast<tc0140syt_device &>(*device).set_slave_tag("^" _tag);
+ downcast<tc0140syt_device &>(*device).set_slave_tag(_tag);
#define MCFG_PC060HA_MASTER_CPU(_tag) MCFG_TC0140SYT_MASTER_CPU(_tag)
#define MCFG_PC060HA_SLAVE_CPU(_tag) MCFG_TC0140SYT_SLAVE_CPU(_tag)
diff --git a/src/mame/drivers/4enlinea.cpp b/src/mame/drivers/4enlinea.cpp
index 6eb4c436e6b..2c3df6bc81c 100644
--- a/src/mame/drivers/4enlinea.cpp
+++ b/src/mame/drivers/4enlinea.cpp
@@ -513,7 +513,7 @@ MACHINE_CONFIG_START(_4enlinea_state::_4enlinea)
MCFG_CPU_PERIODIC_INT_DRIVER(_4enlinea_state, _4enlinea_audio_irq, 60) //TODO
MCFG_DEVICE_ADD("isa", ISA8, 0)
- MCFG_ISA8_CPU(":maincpu")
+ MCFG_ISA8_CPU("maincpu")
MCFG_ISA8_SLOT_ADD("isa", "isa1", 4enlinea_isa8_cards, "4enlinea", true)
diff --git a/src/mame/drivers/asst128.cpp b/src/mame/drivers/asst128.cpp
index a353585494f..3e73e3ae57e 100644
--- a/src/mame/drivers/asst128.cpp
+++ b/src/mame/drivers/asst128.cpp
@@ -105,7 +105,7 @@ MACHINE_CONFIG_START(asst128_state::asst128)
MCFG_CPU_IRQ_ACKNOWLEDGE_DEVICE("mb:pic8259", pic8259_device, inta_cb)
MCFG_DEVICE_ADD("mb", ASST128_MOTHERBOARD, 0)
- downcast<asst128_mb_device &>(*device).set_cputag("^maincpu");
+ downcast<asst128_mb_device &>(*device).set_cputag("maincpu");
MCFG_DEVICE_INPUT_DEFAULTS(asst128)
MCFG_DEVICE_MODIFY("mb:cassette")
diff --git a/src/mame/drivers/at.cpp b/src/mame/drivers/at.cpp
index 2316b136a79..0fc410231ac 100644
--- a/src/mame/drivers/at.cpp
+++ b/src/mame/drivers/at.cpp
@@ -633,7 +633,7 @@ MACHINE_CONFIG_START(megapc_state::megapc)
// on board devices
MCFG_DEVICE_ADD("isabus", ISA16, 0)
- MCFG_ISA16_CPU(":maincpu")
+ MCFG_ISA16_CPU("maincpu")
MCFG_ISA_BUS_IOCHCK(DEVWRITELINE("wd7600", wd7600_device, iochck_w))
MCFG_ISA_OUT_IRQ2_CB(DEVWRITELINE("wd7600", wd7600_device, irq09_w))
MCFG_ISA_OUT_IRQ3_CB(DEVWRITELINE("wd7600", wd7600_device, irq03_w))
diff --git a/src/mame/drivers/ct486.cpp b/src/mame/drivers/ct486.cpp
index 44824156745..a09ec617100 100644
--- a/src/mame/drivers/ct486.cpp
+++ b/src/mame/drivers/ct486.cpp
@@ -145,7 +145,7 @@ MACHINE_CONFIG_START(ct486_state::ct486)
MCFG_PC_KBDC_SLOT_ADD("pc_kbdc", "kbd", pc_at_keyboards, STR_KBD_MICROSOFT_NATURAL)
MCFG_DEVICE_ADD("isabus", ISA16, 0)
- MCFG_ISA16_CPU(":maincpu")
+ MCFG_ISA16_CPU("maincpu")
MCFG_ISA_BUS_IOCHCK(DEVWRITELINE("cs4031", cs4031_device, iochck_w))
MCFG_ISA_OUT_IRQ2_CB(DEVWRITELINE("cs4031", cs4031_device, irq09_w))
MCFG_ISA_OUT_IRQ3_CB(DEVWRITELINE("cs4031", cs4031_device, irq03_w))
diff --git a/src/mame/drivers/fruitpc.cpp b/src/mame/drivers/fruitpc.cpp
index e1e1b22b099..43db9226b67 100644
--- a/src/mame/drivers/fruitpc.cpp
+++ b/src/mame/drivers/fruitpc.cpp
@@ -147,7 +147,7 @@ MACHINE_CONFIG_START(fruitpc_state::fruitpc)
MCFG_I8237_OUT_IOW_1_CB(WRITE8(fruitpc_state, dma8237_1_dack_w))
MCFG_DEVICE_ADD("isa", ISA8, 0)
- MCFG_ISA8_CPU(":maincpu")
+ MCFG_ISA8_CPU("maincpu")
MCFG_ISA_OUT_IRQ2_CB(DEVWRITELINE("pic8259_2", pic8259_device, ir2_w))
MCFG_ISA_OUT_IRQ3_CB(DEVWRITELINE("pic8259_1", pic8259_device, ir3_w))
MCFG_ISA_OUT_IRQ4_CB(DEVWRITELINE("pic8259_1", pic8259_device, ir4_w))
diff --git a/src/mame/drivers/gijoe.cpp b/src/mame/drivers/gijoe.cpp
index 98e1bbf217b..b51a21f65a0 100644
--- a/src/mame/drivers/gijoe.cpp
+++ b/src/mame/drivers/gijoe.cpp
@@ -332,7 +332,7 @@ MACHINE_CONFIG_START(gijoe_state::gijoe)
/* sound hardware */
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
- MCFG_K054321_ADD("k054321", ":lspeaker", ":rspeaker")
+ MCFG_K054321_ADD("k054321", "lspeaker", "rspeaker")
MCFG_DEVICE_ADD("k054539", K054539, XTAL(18'432'000))
MCFG_K054539_TIMER_HANDLER(INPUTLINE("audiocpu", INPUT_LINE_NMI))
diff --git a/src/mame/drivers/indiana.cpp b/src/mame/drivers/indiana.cpp
index 8a5a3f63917..8cbed13b2a4 100644
--- a/src/mame/drivers/indiana.cpp
+++ b/src/mame/drivers/indiana.cpp
@@ -95,7 +95,7 @@ MACHINE_CONFIG_START(indiana_state::indiana)
MCFG_CPU_PROGRAM_MAP(indiana_mem)
MCFG_DEVICE_ADD(ISABUS_TAG, ISA16, 0)
- MCFG_ISA16_CPU(":" M68K_TAG)
+ MCFG_ISA16_CPU(M68K_TAG)
MCFG_ISA16_BUS_CUSTOM_SPACES()
MCFG_ISA16_SLOT_ADD(ISABUS_TAG, "isa1", indiana_isa_cards, "vga", false)
MCFG_ISA16_SLOT_ADD(ISABUS_TAG, "isa2", indiana_isa_cards, "fdc_at", false)
diff --git a/src/mame/drivers/lethal.cpp b/src/mame/drivers/lethal.cpp
index e6f52dae714..c71a57ffb05 100644
--- a/src/mame/drivers/lethal.cpp
+++ b/src/mame/drivers/lethal.cpp
@@ -537,7 +537,7 @@ MACHINE_CONFIG_START(lethal_state::lethalen)
/* sound hardware */
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
- MCFG_K054321_ADD("k054321", ":lspeaker", ":rspeaker")
+ MCFG_K054321_ADD("k054321", "lspeaker", "rspeaker")
MCFG_DEVICE_ADD("k054539", K054539, XTAL(18'432'000))
MCFG_K054539_TIMER_HANDLER(INPUTLINE("soundcpu", INPUT_LINE_NMI))
diff --git a/src/mame/drivers/magtouch.cpp b/src/mame/drivers/magtouch.cpp
index 56ae4fb6c97..961fad1479c 100644
--- a/src/mame/drivers/magtouch.cpp
+++ b/src/mame/drivers/magtouch.cpp
@@ -212,7 +212,7 @@ MACHINE_CONFIG_START(magtouch_state::magtouch)
MCFG_I8237_OUT_IOW_1_CB(WRITE8(magtouch_state, dma8237_1_dack_w))
MCFG_DEVICE_ADD("isa", ISA8, 0)
- MCFG_ISA8_CPU(":maincpu")
+ MCFG_ISA8_CPU("maincpu")
MCFG_ISA_OUT_IRQ2_CB(DEVWRITELINE("pic8259_2", pic8259_device, ir2_w))
MCFG_ISA_OUT_IRQ3_CB(DEVWRITELINE("pic8259_1", pic8259_device, ir3_w))
//MCFG_ISA_OUT_IRQ4_CB(DEVWRITELINE("pic8259_1", pic8259_device, ir4_w))
diff --git a/src/mame/drivers/mc1502.cpp b/src/mame/drivers/mc1502.cpp
index d944fcde151..9d7cc298943 100644
--- a/src/mame/drivers/mc1502.cpp
+++ b/src/mame/drivers/mc1502.cpp
@@ -284,7 +284,7 @@ MACHINE_CONFIG_START(mc1502_state::mc1502)
MCFG_RS232_CTS_HANDLER(DEVWRITELINE("upd8251", i8251_device, write_cts))
MCFG_DEVICE_ADD("isa", ISA8, 0)
- MCFG_ISA8_CPU(":maincpu")
+ MCFG_ISA8_CPU("maincpu")
MCFG_ISA_OUT_IRQ2_CB(DEVWRITELINE("pic8259", pic8259_device, ir2_w))
MCFG_ISA_OUT_IRQ3_CB(DEVWRITELINE("pic8259", pic8259_device, ir3_w))
MCFG_ISA_OUT_IRQ4_CB(DEVWRITELINE("pic8259", pic8259_device, ir4_w))
diff --git a/src/mame/drivers/model2.cpp b/src/mame/drivers/model2.cpp
index cee01b2303d..7ae2caac2ea 100644
--- a/src/mame/drivers/model2.cpp
+++ b/src/mame/drivers/model2.cpp
@@ -2805,8 +2805,8 @@ MACHINE_CONFIG_START(model2c_state::model2c)
MCFG_CPU_ADD("copro_tgpx4", MB86235, 40000000)
MCFG_CPU_PROGRAM_MAP(copro_tgpx4_map)
MCFG_CPU_DATA_MAP(copro_tgpx4_data_map)
- MCFG_MB86235_FIFOIN(":copro_fifo_in")
- MCFG_MB86235_FIFOOUT0(":copro_fifo_out")
+ MCFG_MB86235_FIFOIN("copro_fifo_in")
+ MCFG_MB86235_FIFOOUT0("copro_fifo_out")
MCFG_DEVICE_ADD("copro_fifo_in", GENERIC_FIFO_U32, 0)
MCFG_DEVICE_ADD("copro_fifo_out", GENERIC_FIFO_U32, 0)
diff --git a/src/mame/drivers/moo.cpp b/src/mame/drivers/moo.cpp
index 0f9ac55f5ec..c908922eb33 100644
--- a/src/mame/drivers/moo.cpp
+++ b/src/mame/drivers/moo.cpp
@@ -545,7 +545,7 @@ MACHINE_CONFIG_START(moo_state::moo)
/* sound hardware */
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
- MCFG_K054321_ADD("k054321", ":lspeaker", ":rspeaker")
+ MCFG_K054321_ADD("k054321", "lspeaker", "rspeaker")
MCFG_YM2151_ADD("ymsnd", XTAL(32'000'000)/8) // 4MHz verified
MCFG_SOUND_ROUTE(0, "lspeaker", 0.50)
diff --git a/src/mame/drivers/myb3k.cpp b/src/mame/drivers/myb3k.cpp
index d7d2081f875..fc95db68df6 100644
--- a/src/mame/drivers/myb3k.cpp
+++ b/src/mame/drivers/myb3k.cpp
@@ -987,7 +987,7 @@ MACHINE_CONFIG_START(myb3k_state::myb3k)
/* ISA8+ Expansion bus */
MCFG_DEVICE_ADD("isa", ISA8, 0)
- MCFG_ISA8_CPU(":maincpu")
+ MCFG_ISA8_CPU("maincpu")
MCFG_ISA_OUT_IRQ2_CB(DEVWRITELINE("pic", pic8259_device, ir2_w))
MCFG_ISA_OUT_IRQ3_CB(DEVWRITELINE("pic", pic8259_device, ir3_w))
MCFG_ISA_OUT_IRQ4_CB(DEVWRITELINE("pic", pic8259_device, ir4_w))
diff --git a/src/mame/drivers/mystwarr.cpp b/src/mame/drivers/mystwarr.cpp
index 855d414ad04..5a45a540463 100644
--- a/src/mame/drivers/mystwarr.cpp
+++ b/src/mame/drivers/mystwarr.cpp
@@ -996,7 +996,7 @@ MACHINE_CONFIG_START(mystwarr_state::mystwarr)
/* sound hardware */
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
- MCFG_K054321_ADD("k054321", ":lspeaker", ":rspeaker")
+ MCFG_K054321_ADD("k054321", "lspeaker", "rspeaker")
MCFG_DEVICE_ADD("k054539_1", K054539, XTAL(18'432'000))
MCFG_DEVICE_ADDRESS_MAP(0, mystwarr_k054539_map)
diff --git a/src/mame/drivers/pc1512.cpp b/src/mame/drivers/pc1512.cpp
index 49382da6000..7c5765fd447 100644
--- a/src/mame/drivers/pc1512.cpp
+++ b/src/mame/drivers/pc1512.cpp
@@ -1238,7 +1238,7 @@ MACHINE_CONFIG_START(pc1512_state::pc1512)
// ISA8 bus
MCFG_DEVICE_ADD(ISA_BUS_TAG, ISA8, 0)
- MCFG_ISA8_CPU(":" I8086_TAG)
+ MCFG_ISA8_CPU(I8086_TAG)
MCFG_ISA_OUT_IRQ2_CB(DEVWRITELINE(I8259A2_TAG, pic8259_device, ir2_w))
MCFG_ISA_OUT_IRQ3_CB(DEVWRITELINE(I8259A2_TAG, pic8259_device, ir3_w))
MCFG_ISA_OUT_IRQ4_CB(DEVWRITELINE(I8259A2_TAG, pic8259_device, ir4_w))
@@ -1372,7 +1372,7 @@ MACHINE_CONFIG_START(pc1640_state::pc1640)
// ISA8 bus
MCFG_DEVICE_ADD(ISA_BUS_TAG, ISA8, 0)
- MCFG_ISA8_CPU(":" I8086_TAG)
+ MCFG_ISA8_CPU(I8086_TAG)
MCFG_ISA_OUT_IRQ2_CB(DEVWRITELINE(I8259A2_TAG, pic8259_device, ir2_w))
MCFG_ISA_OUT_IRQ3_CB(DEVWRITELINE(I8259A2_TAG, pic8259_device, ir3_w))
MCFG_ISA_OUT_IRQ4_CB(DEVWRITELINE(I8259A2_TAG, pic8259_device, ir4_w))
diff --git a/src/mame/drivers/pcat_dyn.cpp b/src/mame/drivers/pcat_dyn.cpp
index 2a1db32a81e..f83859e3b60 100644
--- a/src/mame/drivers/pcat_dyn.cpp
+++ b/src/mame/drivers/pcat_dyn.cpp
@@ -203,7 +203,7 @@ MACHINE_CONFIG_START(pcat_dyn_state::pcat_dyn)
MCFG_RS232_CTS_HANDLER(DEVWRITELINE("ns16550", ins8250_uart_device, cts_w))
MCFG_DEVICE_ADD("isa", ISA8, 0)
- MCFG_ISA8_CPU(":maincpu")
+ MCFG_ISA8_CPU("maincpu")
MCFG_ISA_OUT_IRQ2_CB(DEVWRITELINE("pic8259_2", pic8259_device, ir2_w))
MCFG_ISA_OUT_IRQ3_CB(DEVWRITELINE("pic8259_1", pic8259_device, ir3_w))
//MCFG_ISA_OUT_IRQ4_CB(DEVWRITELINE("pic8259_1", pic8259_device, ir4_w))
diff --git a/src/mame/drivers/plygonet.cpp b/src/mame/drivers/plygonet.cpp
index f9b866151e8..9147ddc52fa 100644
--- a/src/mame/drivers/plygonet.cpp
+++ b/src/mame/drivers/plygonet.cpp
@@ -590,7 +590,7 @@ MACHINE_CONFIG_START(polygonet_state::plygonet)
/* sound hardware */
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
- MCFG_K054321_ADD("k054321", ":lspeaker", ":rspeaker")
+ MCFG_K054321_ADD("k054321", "lspeaker", "rspeaker")
MCFG_DEVICE_ADD("k054539", K054539, XTAL(18'432'000))
MCFG_K054539_TIMER_HANDLER(WRITELINE(polygonet_state, k054539_nmi_gen))
diff --git a/src/mame/drivers/poisk1.cpp b/src/mame/drivers/poisk1.cpp
index f15947701cb..b0279325de1 100644
--- a/src/mame/drivers/poisk1.cpp
+++ b/src/mame/drivers/poisk1.cpp
@@ -675,7 +675,7 @@ MACHINE_CONFIG_START(p1_state::poisk1)
MCFG_I8255_IN_PORTC_CB(READ8(p1_state, p1_ppi2_portc_r)) /*62H*/
MCFG_DEVICE_ADD("isa", ISA8, 0)
- MCFG_ISA8_CPU(":maincpu")
+ MCFG_ISA8_CPU("maincpu")
MCFG_ISA_OUT_IRQ2_CB(DEVWRITELINE("pic8259", pic8259_device, ir2_w))
MCFG_ISA_OUT_IRQ3_CB(DEVWRITELINE("pic8259", pic8259_device, ir3_w))
MCFG_ISA_OUT_IRQ4_CB(DEVWRITELINE("pic8259", pic8259_device, ir4_w))
diff --git a/src/mame/drivers/pt68k4.cpp b/src/mame/drivers/pt68k4.cpp
index 0b16a985291..cb96355d3b1 100644
--- a/src/mame/drivers/pt68k4.cpp
+++ b/src/mame/drivers/pt68k4.cpp
@@ -423,7 +423,7 @@ MACHINE_CONFIG_START(pt68k4_state::pt68k2)
MCFG_FLOPPY_DRIVE_ADD(WDFDC_TAG":1", pt68k_floppies, "525dd", pt68k4_state::floppy_formats)
MCFG_DEVICE_ADD(ISABUS_TAG, ISA8, 0)
- MCFG_ISA8_CPU(":" M68K_TAG)
+ MCFG_ISA8_CPU(M68K_TAG)
MCFG_ISA8_BUS_CUSTOM_SPACES()
MCFG_ISA_OUT_IRQ5_CB(WRITELINE(pt68k4_state, irq5_w))
MCFG_ISA8_SLOT_ADD(ISABUS_TAG, "isa1", pt68k4_isa8_cards, "cga", false)
@@ -460,7 +460,7 @@ MACHINE_CONFIG_START(pt68k4_state::pt68k4)
MCFG_M48T02_ADD(TIMEKEEPER_TAG)
MCFG_DEVICE_ADD(ISABUS_TAG, ISA8, 0)
- MCFG_ISA8_CPU(":" M68K_TAG)
+ MCFG_ISA8_CPU(M68K_TAG)
MCFG_ISA8_BUS_CUSTOM_SPACES()
MCFG_ISA8_SLOT_ADD(ISABUS_TAG, "isa1", pt68k4_isa8_cards, "fdc_at", false)
MCFG_ISA8_SLOT_ADD(ISABUS_TAG, "isa2", pt68k4_isa8_cards, "cga", false)
diff --git a/src/mame/drivers/rungun.cpp b/src/mame/drivers/rungun.cpp
index f5ae658eecf..95403525439 100644
--- a/src/mame/drivers/rungun.cpp
+++ b/src/mame/drivers/rungun.cpp
@@ -445,7 +445,7 @@ MACHINE_CONFIG_START(rungun_state::rng)
/* sound hardware */
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
- MCFG_K054321_ADD("k054321", ":lspeaker", ":rspeaker")
+ MCFG_K054321_ADD("k054321", "lspeaker", "rspeaker")
MCFG_DEVICE_ADD("k054539_1", K054539, XTAL(18'432'000))
MCFG_DEVICE_ADDRESS_MAP(0, rungun_k054539_map)
diff --git a/src/mame/drivers/savquest.cpp b/src/mame/drivers/savquest.cpp
index 2f31185b4b7..80867511475 100644
--- a/src/mame/drivers/savquest.cpp
+++ b/src/mame/drivers/savquest.cpp
@@ -835,7 +835,7 @@ MACHINE_CONFIG_START(savquest_state::savquest)
/* sound hardware */
MCFG_DEVICE_ADD("isa", ISA16, 0)
- MCFG_ISA16_CPU(":maincpu")
+ MCFG_ISA16_CPU("maincpu")
MCFG_ISA16_SLOT_ADD("isa", "isa1", savquest_isa16_cards, "sb16", false)
/* video hardware */
diff --git a/src/mame/drivers/tandy1t.cpp b/src/mame/drivers/tandy1t.cpp
index c2545f9b193..8ab4b6efbc5 100644
--- a/src/mame/drivers/tandy1t.cpp
+++ b/src/mame/drivers/tandy1t.cpp
@@ -648,7 +648,7 @@ GFXDECODE_END
MACHINE_CONFIG_START(tandy1000_state::tandy1000_common)
MCFG_DEVICE_ADD("mb", T1000_MOTHERBOARD, 0)
- downcast<t1000_mb_device &>(*device).set_cputag("^maincpu");
+ downcast<t1000_mb_device &>(*device).set_cputag("maincpu");
/* video hardware */
MCFG_PCVIDEO_T1000_ADD("pcvideo_t1000")
diff --git a/src/mame/drivers/vis.cpp b/src/mame/drivers/vis.cpp
index 25e2ecf486d..fe84573ac6c 100644
--- a/src/mame/drivers/vis.cpp
+++ b/src/mame/drivers/vis.cpp
@@ -239,7 +239,6 @@ private:
rgb_t yuv_to_rgb(int y, int u, int v) const;
virtual uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) override;
- std::string m_screen_tag;
int m_extcnt;
uint8_t m_extreg;
uint8_t m_interlace;
@@ -250,12 +249,11 @@ private:
DEFINE_DEVICE_TYPE(VIS_VGA, vis_vga_device, "vis_vga", "vis_vga")
-vis_vga_device::vis_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
- : svga_device(mconfig, VIS_VGA, tag, owner, clock),
- device_isa16_card_interface(mconfig, *this),
- m_screen_tag(subtag("screen"))
+vis_vga_device::vis_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
+ svga_device(mconfig, VIS_VGA, tag, owner, clock),
+ device_isa16_card_interface(mconfig, *this)
{
- set_screen(m_screen_tag.c_str());
+ set_screen(*this, "screen");
}
MACHINE_CONFIG_START(vis_vga_device::device_add_mconfig)
diff --git a/src/mame/drivers/wpc_an.cpp b/src/mame/drivers/wpc_an.cpp
index 6777e6f8f52..3abe7ba7763 100644
--- a/src/mame/drivers/wpc_an.cpp
+++ b/src/mame/drivers/wpc_an.cpp
@@ -344,7 +344,7 @@ MACHINE_CONFIG_START(wpc_an_state::wpc_an)
MCFG_SPEAKER_STANDARD_MONO("speaker")
MCFG_SOUND_ADD("wpcsnd", WPCSND, 0)
- MCFG_WPC_ROM_REGION(":sound1")
+ MCFG_WPC_ROM_REGION("sound1")
MCFG_WPC_SOUND_REPLY_CALLBACK(WRITELINE(wpc_an_state,wpcsnd_reply_w))
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 1.0)
MACHINE_CONFIG_END
diff --git a/src/mame/drivers/wpc_dot.cpp b/src/mame/drivers/wpc_dot.cpp
index 9e7879dc3b8..b6717407e95 100644
--- a/src/mame/drivers/wpc_dot.cpp
+++ b/src/mame/drivers/wpc_dot.cpp
@@ -317,7 +317,7 @@ MACHINE_CONFIG_START(wpc_dot_state::wpc_dot)
MCFG_SPEAKER_STANDARD_MONO("speaker")
MCFG_SOUND_ADD("wpcsnd", WPCSND, 0)
- MCFG_WPC_ROM_REGION(":sound1")
+ MCFG_WPC_ROM_REGION("sound1")
MCFG_WPC_SOUND_REPLY_CALLBACK(WRITELINE(wpc_dot_state,wpcsnd_reply_w))
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 1.0)
diff --git a/src/mame/drivers/wpc_flip1.cpp b/src/mame/drivers/wpc_flip1.cpp
index 8bb7bf1d17e..c86b7445ab7 100644
--- a/src/mame/drivers/wpc_flip1.cpp
+++ b/src/mame/drivers/wpc_flip1.cpp
@@ -173,7 +173,7 @@ MACHINE_CONFIG_START(wpc_flip1_state::wpc_flip1)
MCFG_SPEAKER_STANDARD_MONO("speaker")
MCFG_SOUND_ADD("wpcsnd", WPCSND, 0)
- MCFG_WPC_ROM_REGION(":sound1")
+ MCFG_WPC_ROM_REGION("sound1")
MCFG_WPC_SOUND_REPLY_CALLBACK(WRITELINE(wpc_dot_state,wpcsnd_reply_w))
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 1.0)
diff --git a/src/mame/drivers/wpc_flip2.cpp b/src/mame/drivers/wpc_flip2.cpp
index 2ccd0564864..5e8edefbe12 100644
--- a/src/mame/drivers/wpc_flip2.cpp
+++ b/src/mame/drivers/wpc_flip2.cpp
@@ -202,7 +202,7 @@ MACHINE_CONFIG_START(wpc_flip2_state::wpc_flip2)
MCFG_SPEAKER_STANDARD_MONO("speaker")
MCFG_SOUND_ADD("wpcsnd", WPCSND, 0)
- MCFG_WPC_ROM_REGION(":sound1")
+ MCFG_WPC_ROM_REGION("sound1")
MCFG_WPC_SOUND_REPLY_CALLBACK(WRITELINE(wpc_dot_state,wpcsnd_reply_w))
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 1.0)
diff --git a/src/mame/drivers/xexex.cpp b/src/mame/drivers/xexex.cpp
index 589f2d95117..6c81f42e1ed 100644
--- a/src/mame/drivers/xexex.cpp
+++ b/src/mame/drivers/xexex.cpp
@@ -520,7 +520,7 @@ MACHINE_CONFIG_START(xexex_state::xexex)
/* sound hardware */
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
- MCFG_K054321_ADD("k054321", ":lspeaker", ":rspeaker")
+ MCFG_K054321_ADD("k054321", "lspeaker", "rspeaker")
MCFG_YM2151_ADD("ymsnd", XTAL(32'000'000)/8) // 4MHz
MCFG_SOUND_ROUTE(0, "filter1_l", 0.50)
diff --git a/src/mame/drivers/xmen.cpp b/src/mame/drivers/xmen.cpp
index 704a83874a9..ba9343b4cb6 100644
--- a/src/mame/drivers/xmen.cpp
+++ b/src/mame/drivers/xmen.cpp
@@ -338,7 +338,7 @@ MACHINE_CONFIG_START(xmen_state::xmen)
/* sound hardware */
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
- MCFG_K054321_ADD("k054321", ":lspeaker", ":rspeaker")
+ MCFG_K054321_ADD("k054321", "lspeaker", "rspeaker")
MCFG_YM2151_ADD("ymsnd", XTAL(16'000'000)/4) /* verified on pcb */
MCFG_SOUND_ROUTE(0, "lspeaker", 0.20)
@@ -400,7 +400,7 @@ MACHINE_CONFIG_START(xmen_state::xmen6p)
MCFG_K053251_ADD("k053251")
- MCFG_K054321_ADD("k054321", ":lspeaker", ":rspeaker")
+ MCFG_K054321_ADD("k054321", "lspeaker", "rspeaker")
/* sound hardware */
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
diff --git a/src/mame/machine/awboard.h b/src/mame/machine/awboard.h
index a9f875c9cab..821e1c869da 100644
--- a/src/mame/machine/awboard.h
+++ b/src/mame/machine/awboard.h
@@ -9,7 +9,7 @@
#define MCFG_AW_ROM_BOARD_ADD(_tag, _keyregion, _irq_cb) \
MCFG_NAOMI_G1_ADD(_tag, AW_ROM_BOARD, _irq_cb) \
- aw_rom_board::static_set_keyregion(*device, "^" _keyregion);
+ aw_rom_board::static_set_keyregion(*device, _keyregion);
class aw_rom_board : public naomi_g1_device
{
diff --git a/src/mame/machine/deco_irq.h b/src/mame/machine/deco_irq.h
index 8266d31563e..bc559c9cbf0 100644
--- a/src/mame/machine/deco_irq.h
+++ b/src/mame/machine/deco_irq.h
@@ -20,7 +20,7 @@
#define MCFG_DECO_IRQ_ADD(_tag, _screen_tag) \
MCFG_DEVICE_ADD(_tag, DECO_IRQ, 0) \
- downcast<deco_irq_device &>(*device).set_screen_tag("^" _screen_tag);
+ downcast<deco_irq_device &>(*device).set_screen_tag(_screen_tag);
#define MCFG_DECO_IRQ_LIGHTGUN1_CB(_devcb) \
devcb = &downcast<deco_irq_device &>(*device).set_lightgun1_callback(DEVCB_##_devcb);
diff --git a/src/mame/machine/hpc3.h b/src/mame/machine/hpc3.h
index e654e56156e..b8553738b3a 100644
--- a/src/mame/machine/hpc3.h
+++ b/src/mame/machine/hpc3.h
@@ -19,13 +19,13 @@
MCFG_DEVICE_ADD(_tag, SGI_HPC3, 0)
#define MCFG_HPC3_CPU_TAG(cpu_tag) \
- downcast<hpc3_device &>(*device).set_cpu_tag(("^" cpu_tag));
+ downcast<hpc3_device &>(*device).set_cpu_tag(cpu_tag);
#define MCFG_HPC3_SCSI_TAG(scsi_tag) \
- downcast<hpc3_device &>(*device).set_scsi_tag(("^" scsi_tag));
+ downcast<hpc3_device &>(*device).set_scsi_tag(scsi_tag);
#define MCFG_HPC3_IOC2_TAG(ioc2_tag) \
- downcast<hpc3_device &>(*device).set_ioc2_tag(("^" ioc2_tag));
+ downcast<hpc3_device &>(*device).set_ioc2_tag(ioc2_tag);
class hpc3_device : public device_t
{
@@ -125,4 +125,4 @@ protected:
DECLARE_DEVICE_TYPE(SGI_HPC3, hpc3_device)
-#endif // MAME_MACHINE_HAL2_H \ No newline at end of file
+#endif // MAME_MACHINE_HAL2_H
diff --git a/src/mame/machine/ioc2.h b/src/mame/machine/ioc2.h
index 94d5e8bd987..89b9abb2136 100644
--- a/src/mame/machine/ioc2.h
+++ b/src/mame/machine/ioc2.h
@@ -25,7 +25,7 @@
MCFG_DEVICE_ADD(_tag, SGI_IOC2_FULL_HOUSE, 0)
#define MCFG_IOC2_CPU(cpu_tag) \
- downcast<ioc2_device &>(*device).set_cpu_tag(("^" cpu_tag));
+ downcast<ioc2_device &>(*device).set_cpu_tag(cpu_tag);
class ioc2_device : public device_t
{
@@ -212,4 +212,4 @@ protected:
DECLARE_DEVICE_TYPE(SGI_IOC2_GUINNESS, ioc2_guinness_device)
DECLARE_DEVICE_TYPE(SGI_IOC2_FULL_HOUSE, ioc2_full_house_device)
-#endif // MAME_MACHINE_IOC2_H \ No newline at end of file
+#endif // MAME_MACHINE_IOC2_H
diff --git a/src/mame/machine/mega32x.h b/src/mame/machine/mega32x.h
index e2f39c596dc..169f339bc13 100644
--- a/src/mame/machine/mega32x.h
+++ b/src/mame/machine/mega32x.h
@@ -223,6 +223,6 @@ DECLARE_DEVICE_TYPE(SEGA_32X_NTSC, sega_32x_ntsc_device)
DECLARE_DEVICE_TYPE(SEGA_32X_PAL, sega_32x_pal_device)
#define MCFG_SEGA_32X_PALETTE(_palette_tag) \
- downcast<sega_32x_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<sega_32x_device &>(*device).set_palette_tag(_palette_tag);
#endif // MAME_MACHINE_MEGA32X_H
diff --git a/src/mame/machine/namco06.h b/src/mame/machine/namco06.h
index da58638d10a..a6a411be3ce 100644
--- a/src/mame/machine/namco06.h
+++ b/src/mame/machine/namco06.h
@@ -20,7 +20,7 @@ struct namco_06xx_config
MCFG_DEVICE_ADD(_tag, NAMCO_06XX, _clock)
#define MCFG_NAMCO_06XX_MAINCPU(_tag) \
- downcast<namco_06xx_device &>(*device).set_maincpu("^" _tag);
+ downcast<namco_06xx_device &>(*device).set_maincpu(_tag);
#define MCFG_NAMCO_06XX_READ_0_CB(_devcb) \
devcb = &downcast<namco_06xx_device &>(*device).set_read_callback<0>(DEVCB_##_devcb);
diff --git a/src/mame/machine/namco51.h b/src/mame/machine/namco51.h
index 272950dbfad..54e06dae404 100644
--- a/src/mame/machine/namco51.h
+++ b/src/mame/machine/namco51.h
@@ -12,7 +12,7 @@
MCFG_DEVICE_ADD(_tag, NAMCO_51XX, _clock)
#define MCFG_NAMCO_51XX_SCREEN(screen_tag) \
- downcast<namco_51xx_device &>(*device).set_screen_tag(("^" screen_tag));
+ downcast<namco_51xx_device &>(*device).set_screen_tag(screen_tag);
#define MCFG_NAMCO_51XX_INPUT_0_CB(_devcb) \
devcb = &downcast<namco_51xx_device &>(*device).set_input_callback<0>(DEVCB_##_devcb);
diff --git a/src/mame/machine/naomim4.h b/src/mame/machine/naomim4.h
index f8fb3ad517c..28ef730a1b3 100644
--- a/src/mame/machine/naomim4.h
+++ b/src/mame/machine/naomim4.h
@@ -7,7 +7,7 @@
#define MCFG_NAOMI_M4_BOARD_ADD(_tag, _key_tag, _eeprom_tag, _irq_cb) \
MCFG_NAOMI_BOARD_ADD(_tag, NAOMI_M4_BOARD, _eeprom_tag, _irq_cb) \
- downcast<naomi_m4_board &>(*device).set_tags("^" _key_tag);
+ downcast<naomi_m4_board &>(*device).set_tags(_key_tag);
class naomi_m4_board : public naomi_board
{
diff --git a/src/mame/machine/segaic16.h b/src/mame/machine/segaic16.h
index baf37378c41..9a6a5027045 100644
--- a/src/mame/machine/segaic16.h
+++ b/src/mame/machine/segaic16.h
@@ -22,7 +22,7 @@
//**************************************************************************
#define MCFG_SEGA_315_5195_CPU(_cputag) \
- downcast<sega_315_5195_mapper_device &>(*device).set_cputag("^" _cputag);
+ downcast<sega_315_5195_mapper_device &>(*device).set_cputag(_cputag);
#define MCFG_SEGA_315_5195_MAPPER_HANDLER(_class, _mapper) \
downcast<sega_315_5195_mapper_device &>(*device).set_mapper(sega_315_5195_mapper_device::mapper_delegate(&_class::_mapper, #_class "::" #_mapper, nullptr, (_class *)nullptr));
#define MCFG_SEGA_315_5195_PBF_CALLBACK(_devcb) \
@@ -183,8 +183,8 @@ private:
// internal state
address_space * m_space;
address_space * m_decrypted_space;
- uint8_t m_regs[0x20];
- uint8_t m_curregion;
+ uint8_t m_regs[0x20];
+ uint8_t m_curregion;
decrypt_bank m_banks[8];
// communication registers
diff --git a/src/mame/video/atarimo.h b/src/mame/video/atarimo.h
index 44e60b5ea06..01863bd1b4b 100644
--- a/src/mame/video/atarimo.h
+++ b/src/mame/video/atarimo.h
@@ -24,7 +24,7 @@
downcast<atari_motion_objects_device &>(*device).set_config(_config);
#define MCFG_ATARI_MOTION_OBJECTS_GFXDECODE(_gfxtag) \
- downcast<atari_motion_objects_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<atari_motion_objects_device &>(*device).set_gfxdecode_tag(_gfxtag);
//**************************************************************************
diff --git a/src/mame/video/atarivad.h b/src/mame/video/atarivad.h
index 1bdc95cc444..a7461bff3c9 100644
--- a/src/mame/video/atarivad.h
+++ b/src/mame/video/atarivad.h
@@ -26,7 +26,7 @@
#define MCFG_ATARI_VAD_PLAYFIELD(_class, _gfxtag, _getinfo) \
{ std::string fulltag(device->tag()); fulltag.append(":playfield"); device_t *device; \
MCFG_TILEMAP_ADD(fulltag.c_str()) \
- MCFG_TILEMAP_GFXDECODE("^" _gfxtag) \
+ MCFG_TILEMAP_GFXDECODE(_gfxtag) \
MCFG_TILEMAP_BYTES_PER_ENTRY(2) \
MCFG_TILEMAP_INFO_CB_DEVICE(DEVICE_SELF_OWNER, _class, _getinfo) \
MCFG_TILEMAP_TILE_SIZE(8,8) \
@@ -35,7 +35,7 @@
#define MCFG_ATARI_VAD_PLAYFIELD2(_class, _gfxtag, _getinfo) \
{ std::string fulltag(device->tag()); fulltag.append(":playfield2"); device_t *device; \
MCFG_TILEMAP_ADD(fulltag.c_str()) \
- MCFG_TILEMAP_GFXDECODE("^" _gfxtag) \
+ MCFG_TILEMAP_GFXDECODE(_gfxtag) \
MCFG_TILEMAP_BYTES_PER_ENTRY(2) \
MCFG_TILEMAP_INFO_CB_DEVICE(DEVICE_SELF_OWNER, _class, _getinfo) \
MCFG_TILEMAP_TILE_SIZE(8,8) \
@@ -45,7 +45,7 @@
#define MCFG_ATARI_VAD_ALPHA(_class, _gfxtag, _getinfo) \
{ std::string fulltag(device->tag()); fulltag.append(":alpha"); device_t *device; \
MCFG_TILEMAP_ADD(fulltag.c_str()) \
- MCFG_TILEMAP_GFXDECODE("^" _gfxtag) \
+ MCFG_TILEMAP_GFXDECODE(_gfxtag) \
MCFG_TILEMAP_BYTES_PER_ENTRY(2) \
MCFG_TILEMAP_INFO_CB_DEVICE(DEVICE_SELF_OWNER, _class, _getinfo) \
MCFG_TILEMAP_TILE_SIZE(8,8) \
@@ -54,8 +54,8 @@
#define MCFG_ATARI_VAD_MOB(_config, _gfxtag) \
{ std::string fulltag(device->tag()); fulltag.append(":mob"); device_t *device; \
- MCFG_ATARI_MOTION_OBJECTS_ADD(fulltag.c_str(), "^^screen", _config) \
- MCFG_ATARI_MOTION_OBJECTS_GFXDECODE("^" _gfxtag) }
+ MCFG_ATARI_MOTION_OBJECTS_ADD(fulltag.c_str(), "screen", _config) \
+ MCFG_ATARI_MOTION_OBJECTS_GFXDECODE(_gfxtag) }
diff --git a/src/mame/video/avgdvg.h b/src/mame/video/avgdvg.h
index 812dc290740..40cdc2a803b 100644
--- a/src/mame/video/avgdvg.h
+++ b/src/mame/video/avgdvg.h
@@ -9,7 +9,7 @@
#include "video/vector.h"
#define MCFG_AVGDVG_VECTOR(_tag) \
- downcast<avgdvg_device &>(*device).set_vector_tag("^" _tag);
+ downcast<avgdvg_device &>(*device).set_vector_tag(_tag);
// ======================> avgdvg_device
diff --git a/src/mame/video/decbac06.h b/src/mame/video/decbac06.h
index 7b7e19a0d8f..8888b00d333 100644
--- a/src/mame/video/decbac06.h
+++ b/src/mame/video/decbac06.h
@@ -149,7 +149,7 @@ private:
DECLARE_DEVICE_TYPE(DECO_BAC06, deco_bac06_device)
#define MCFG_DECO_BAC06_GFXDECODE(_gfxtag) \
- downcast<deco_bac06_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<deco_bac06_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_DECO_BAC06_GFX_REGION_WIDE(_8x8, _16x16, _wide) \
downcast<deco_bac06_device &>(*device).set_gfx_region_wide(_8x8, _16x16, _wide);
diff --git a/src/mame/video/deckarn.h b/src/mame/video/deckarn.h
index ef76cffd402..3649882d534 100644
--- a/src/mame/video/deckarn.h
+++ b/src/mame/video/deckarn.h
@@ -31,7 +31,7 @@ private:
DECLARE_DEVICE_TYPE(DECO_KARNOVSPRITES, deco_karnovsprites_device)
#define MCFG_DECO_KARNOVSPRITES_GFXDECODE(_gfxtag) \
- downcast<deco_karnovsprites_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<deco_karnovsprites_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_DECO_KARNOVSPRITES_GFX_REGION(_region) \
downcast<deco_karnovsprites_device &>(*device).set_gfx_region(_region);
diff --git a/src/mame/video/decmxc06.h b/src/mame/video/decmxc06.h
index 95c8046d874..c27bfbc1438 100644
--- a/src/mame/video/decmxc06.h
+++ b/src/mame/video/decmxc06.h
@@ -38,7 +38,7 @@ private:
DECLARE_DEVICE_TYPE(DECO_MXC06, deco_mxc06_device)
#define MCFG_DECO_MXC06_GFXDECODE(_gfxtag) \
- downcast<deco_mxc06_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<deco_mxc06_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_DECO_MXC06_GFX_REGION(_region) \
downcast<deco_mxc06_device &>(*device).set_gfx_region(_region);
diff --git a/src/mame/video/deco16ic.h b/src/mame/video/deco16ic.h
index 761286be68f..3ecd5f53f33 100644
--- a/src/mame/video/deco16ic.h
+++ b/src/mame/video/deco16ic.h
@@ -212,7 +212,7 @@ DECLARE_DEVICE_TYPE(DECO16IC, deco16ic_device)
downcast<deco16ic_device &>(*device).set_pf12_16x16_bank(_bank);
#define MCFG_DECO16IC_GFXDECODE(_gfxtag) \
- downcast<deco16ic_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<deco16ic_device &>(*device).set_gfxdecode_tag(_gfxtag);
// function definition for a callback
#define DECO16IC_BANK_CB_MEMBER(_name) int _name(int bank)
diff --git a/src/mame/video/deco_ace.h b/src/mame/video/deco_ace.h
index b1ed3547a27..9ee104905bd 100644
--- a/src/mame/video/deco_ace.h
+++ b/src/mame/video/deco_ace.h
@@ -69,6 +69,6 @@ DECLARE_DEVICE_TYPE(DECO_ACE, deco_ace_device)
MCFG_DEVICE_ADD(_tag, DECO_ACE, 0)
#define MCFG_DECO_ACE_PALETTE(_palette_tag) \
- downcast<deco_ace_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<deco_ace_device &>(*device).set_palette_tag(_palette_tag);
#endif // MAME_VIDEO_DECO_ACE_H
diff --git a/src/mame/video/deco_zoomspr.h b/src/mame/video/deco_zoomspr.h
index b26d54c3feb..583e227ce14 100644
--- a/src/mame/video/deco_zoomspr.h
+++ b/src/mame/video/deco_zoomspr.h
@@ -36,6 +36,6 @@ private:
DECLARE_DEVICE_TYPE(DECO_ZOOMSPR, deco_zoomspr_device)
#define MCFG_DECO_ZOOMSPR_GFXDECODE(_gfxtag) \
- downcast<deco_zoomspr_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<deco_zoomspr_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_DECO_ZOOMSPR_H
diff --git a/src/mame/video/decocomn.h b/src/mame/video/decocomn.h
index 77c19e42023..bad8a5f1a0d 100644
--- a/src/mame/video/decocomn.h
+++ b/src/mame/video/decocomn.h
@@ -56,6 +56,6 @@ DECLARE_DEVICE_TYPE(DECOCOMN, decocomn_device)
MCFG_DEVICE_ADD(_tag, DECOCOMN, 0)
#define MCFG_DECOCOMN_PALETTE(_palette_tag) \
- downcast<decocomn_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<decocomn_device &>(*device).set_palette_tag(_palette_tag);
#endif // MAME_VIDEO_DECOCOMN_H
diff --git a/src/mame/video/decospr.h b/src/mame/video/decospr.h
index f1a2922ed97..9853728dc03 100644
--- a/src/mame/video/decospr.h
+++ b/src/mame/video/decospr.h
@@ -99,6 +99,6 @@ DECLARE_DEVICE_TYPE(DECO_SPRITE, decospr_device)
downcast<decospr_device &>(*device).set_offsets(_xoffs, _yoffs);
#define MCFG_DECO_SPRITE_GFXDECODE(_gfxtag) \
- downcast<decospr_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<decospr_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_DECOSPR_H
diff --git a/src/mame/video/decrmc3.h b/src/mame/video/decrmc3.h
index 50b6581a7eb..11d12db7f32 100644
--- a/src/mame/video/decrmc3.h
+++ b/src/mame/video/decrmc3.h
@@ -14,11 +14,11 @@
******************************************************************************/
-#pragma once
-
#ifndef MAME_VIDEO_DECORMC3_H
#define MAME_VIDEO_DECORMC3_H
+#pragma once
+
//**************************************************************************
@@ -40,7 +40,7 @@
// other standard palettes
#define MCFG_DECO_RMC3_ADD_PROMS(_tag, _region, _entries) \
MCFG_DECO_RMC3_ADD(_tag, _entries) \
- downcast<deco_rmc3_device &>(*device).set_prom_region("^" _region); \
+ downcast<deco_rmc3_device &>(*device).set_prom_region(_region); \
downcast<deco_rmc3_device &>(*device).set_init(deco_rmc3_palette_init_delegate(FUNC(deco_rmc3_device::palette_init_proms), downcast<deco_rmc3_device *>(device)));
//#define MCFG_DECO_RMC3_INIT_OWNER(_class, _method)
diff --git a/src/mame/video/dooyong.h b/src/mame/video/dooyong.h
index 787b788eeec..bcf6d890e83 100644
--- a/src/mame/video/dooyong.h
+++ b/src/mame/video/dooyong.h
@@ -9,8 +9,8 @@
#define MCFG_DOOYONG_ROM_TILEMAP_ADD(tag, gfx, num, rom, offset) \
MCFG_DEVICE_ADD(tag, DOOYONG_ROM_TILEMAP, 0) \
- downcast<dooyong_rom_tilemap_device &>(*device).set_gfxdecode_tag("^" gfx); \
- downcast<dooyong_rom_tilemap_device &>(*device).set_tilerom_tag("^" rom); \
+ downcast<dooyong_rom_tilemap_device &>(*device).set_gfxdecode_tag(gfx); \
+ downcast<dooyong_rom_tilemap_device &>(*device).set_tilerom_tag(rom); \
downcast<dooyong_rom_tilemap_device &>(*device).set_gfxnum((num)); \
downcast<dooyong_rom_tilemap_device &>(*device).set_tilerom_offset((offset));
#define MCFG_DOOYONG_ROM_TILEMAP_TRANSPARENT_PEN(pen) \
@@ -20,17 +20,17 @@
#define MCFG_RSHARK_ROM_TILEMAP_ADD(tag, gfx, num, rom, offset, rom2, offset2) \
MCFG_DEVICE_ADD(tag, RSHARK_ROM_TILEMAP, 0) \
- downcast<rshark_rom_tilemap_device &>(*device).set_gfxdecode_tag("^" gfx); \
- downcast<rshark_rom_tilemap_device &>(*device).set_tilerom_tag("^" rom); \
+ downcast<rshark_rom_tilemap_device &>(*device).set_gfxdecode_tag(gfx); \
+ downcast<rshark_rom_tilemap_device &>(*device).set_tilerom_tag(rom); \
downcast<rshark_rom_tilemap_device &>(*device).set_gfxnum((num)); \
downcast<rshark_rom_tilemap_device &>(*device).set_tilerom_offset((offset)); \
downcast<rshark_rom_tilemap_device &>(*device).set_primella_code_bits(13); \
- downcast<rshark_rom_tilemap_device &>(*device).set_colorrom_tag("^" rom2); \
+ downcast<rshark_rom_tilemap_device &>(*device).set_colorrom_tag(rom2); \
downcast<rshark_rom_tilemap_device &>(*device).set_colorrom_offset((offset2));
#define MCFG_DOOYONG_RAM_TILEMAP_ADD(tag, gfx, num) \
MCFG_DEVICE_ADD(tag, DOOYONG_RAM_TILEMAP, 0) \
- downcast<dooyong_ram_tilemap_device &>(*device).set_gfxdecode_tag("^" gfx); \
+ downcast<dooyong_ram_tilemap_device &>(*device).set_gfxdecode_tag(gfx); \
downcast<dooyong_ram_tilemap_device &>(*device).set_gfxnum((num));
diff --git a/src/mame/video/fuukifg.h b/src/mame/video/fuukifg.h
index 209de2bde9c..a523744e921 100644
--- a/src/mame/video/fuukifg.h
+++ b/src/mame/video/fuukifg.h
@@ -44,6 +44,6 @@ private:
DECLARE_DEVICE_TYPE(FUUKI_VIDEO, fuukivid_device)
#define MCFG_FUUKI_VIDEO_GFXDECODE(_gfxtag) \
- downcast<fuukivid_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<fuukivid_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_FUUKIFH_H
diff --git a/src/mame/video/k007121.h b/src/mame/video/k007121.h
index 21ea8d1bb68..3231a4750e8 100644
--- a/src/mame/video/k007121.h
+++ b/src/mame/video/k007121.h
@@ -38,6 +38,6 @@ DECLARE_DEVICE_TYPE(K007121, k007121_device)
MCFG_DEVICE_ADD(_tag, K007121, 0)
#define MCFG_K007121_PALETTE(_palette_tag) \
- downcast<k007121_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<k007121_device &>(*device).set_palette_tag(_palette_tag);
#endif // MAME_VIDEO_K007121_H
diff --git a/src/mame/video/k007342.h b/src/mame/video/k007342.h
index 684796ca463..cf9149ff7e1 100644
--- a/src/mame/video/k007342.h
+++ b/src/mame/video/k007342.h
@@ -61,7 +61,7 @@ DECLARE_DEVICE_TYPE(K007342, k007342_device)
#define MCFG_K007342_ADD(_tag) \
MCFG_DEVICE_ADD(_tag, K007342, 0)
#define MCFG_K007342_GFXDECODE(_gfxtag) \
- downcast<k007342_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<k007342_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_K007342_GFXNUM(_gfxnum) \
downcast<k007342_device &>(*device).set_gfxnum(_gfxnum);
diff --git a/src/mame/video/k007420.h b/src/mame/video/k007420.h
index 37fda922a6f..dca677375a6 100644
--- a/src/mame/video/k007420.h
+++ b/src/mame/video/k007420.h
@@ -42,7 +42,7 @@ DECLARE_DEVICE_TYPE(K007420, k007420_device)
MCFG_DEVICE_ADD(_tag, K007420, 0)
#define MCFG_K007420_PALETTE(_palette_tag) \
- downcast<k007420_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<k007420_device &>(*device).set_palette_tag(_palette_tag);
#define MCFG_K007420_BANK_LIMIT(_limit) \
downcast<k007420_device &>(*device).set_bank_limit(_limit);
diff --git a/src/mame/video/k051960.h b/src/mame/video/k051960.h
index 83e8c8485b8..a5807d3efea 100644
--- a/src/mame/video/k051960.h
+++ b/src/mame/video/k051960.h
@@ -25,7 +25,7 @@ typedef device_delegate<void (int *code, int *color, int *priority, int *shadow)
downcast<k051960_device &>(*device).set_plane_order(_order);
#define MCFG_K051960_SCREEN_TAG(_tag) \
- downcast<k051960_device &>(*device).set_screen_tag("^" _tag);
+ downcast<k051960_device &>(*device).set_screen_tag(_tag);
#define MCFG_K051960_IRQ_HANDLER(_devcb) \
devcb = &downcast<k051960_device &>(*device).set_irq_handler(DEVCB_##_devcb);
diff --git a/src/mame/video/k052109.h b/src/mame/video/k052109.h
index ee28d8fbd87..294ee133366 100644
--- a/src/mame/video/k052109.h
+++ b/src/mame/video/k052109.h
@@ -17,7 +17,7 @@ typedef device_delegate<void (int layer, int bank, int *code, int *color, int *f
downcast<k052109_device &>(*device).set_ram(_ram);
#define MCFG_K052109_SCREEN_TAG(_tag) \
- downcast<k052109_device &>(*device).set_screen_tag("^" _tag);
+ downcast<k052109_device &>(*device).set_screen_tag(_tag);
#define MCFG_K052109_IRQ_HANDLER(_devcb) \
devcb = &downcast<k052109_device &>(*device).set_irq_handler(DEVCB_##_devcb);
diff --git a/src/mame/video/k054156_k054157_k056832.h b/src/mame/video/k054156_k054157_k056832.h
index b6bc6fec7a5..d091e4f0c46 100644
--- a/src/mame/video/k054156_k054157_k056832.h
+++ b/src/mame/video/k054156_k054157_k056832.h
@@ -13,7 +13,7 @@ typedef device_delegate<void (int layer, int *code, int *color, int *flags)> k05
downcast<k056832_device &>(*device).set_k056832_callback(k056832_cb_delegate(&_class::_method, #_class "::" #_method, this));
#define MCFG_K056832_CONFIG(_gfx_reg, _bpp, _big, _djmain_hack, _k055555) \
- downcast<k056832_device &>(*device).set_config("^" _gfx_reg, _bpp, _big, _djmain_hack, _k055555);
+ downcast<k056832_device &>(*device).set_config(_gfx_reg, _bpp, _big, _djmain_hack, _k055555);
#define K056832_PAGE_COUNT 16
diff --git a/src/mame/video/kan_pand.h b/src/mame/video/kan_pand.h
index 0fb809f7678..bb578bead53 100644
--- a/src/mame/video/kan_pand.h
+++ b/src/mame/video/kan_pand.h
@@ -76,6 +76,6 @@ DECLARE_DEVICE_TYPE(KANEKO_PANDORA, kaneko_pandora_device)
downcast<kaneko_pandora_device &>(*device).set_offsets(_xoffs, _yoffs);
#define MCFG_KANEKO_PANDORA_GFXDECODE(_gfxtag) \
- downcast<kaneko_pandora_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<kaneko_pandora_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_KAN_PAND_H
diff --git a/src/mame/video/kaneko_spr.h b/src/mame/video/kaneko_spr.h
index 92217f13125..f5533cc11ec 100644
--- a/src/mame/video/kaneko_spr.h
+++ b/src/mame/video/kaneko_spr.h
@@ -125,7 +125,7 @@ private:
//extern const device_type KANEKO16_SPRITE;
#define MCFG_KANEKO16_SPRITE_GFXDECODE(_gfxtag) \
- downcast<kaneko16_sprite_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<kaneko16_sprite_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_KANEKO16_SPRITE_PRIORITIES(_pri0, _pri1, _pri2, _pri3) \
downcast<kaneko16_sprite_device &>(*device).set_priorities(_pri0, _pri1, _pri2, _pri3);
#define MCFG_KANEKO16_SPRITE_OFFSETS(_xoffs, _yoffs) \
diff --git a/src/mame/video/kaneko_tmap.h b/src/mame/video/kaneko_tmap.h
index 1ba76f73c82..18223847032 100644
--- a/src/mame/video/kaneko_tmap.h
+++ b/src/mame/video/kaneko_tmap.h
@@ -92,7 +92,7 @@ private:
DECLARE_DEVICE_TYPE(KANEKO_TMAP, kaneko_view2_tilemap_device)
#define MCFG_KANEKO_TMAP_GFXDECODE(_gfxtag) \
- downcast<kaneko_view2_tilemap_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<kaneko_view2_tilemap_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_KANEKO_TMAP_GFX_REGION(_region) \
downcast<kaneko_view2_tilemap_device &>(*device).set_gfx_region(_region);
#define MCFG_KANEKO_TMAP_INVERT_FLIP(_invert) \
diff --git a/src/mame/video/ladybug.h b/src/mame/video/ladybug.h
index e1c64537356..72ad9f0c30f 100644
--- a/src/mame/video/ladybug.h
+++ b/src/mame/video/ladybug.h
@@ -9,7 +9,7 @@
#define MCFG_LADYBUG_VIDEO_GFXDECODE(tag) \
- downcast<ladybug_video_device &>(*device).set_gfxdecode_tag("^" tag);
+ downcast<ladybug_video_device &>(*device).set_gfxdecode_tag(tag);
// used by ladybug and sraider
diff --git a/src/mame/video/maria.h b/src/mame/video/maria.h
index c048ebcac49..15f1a68cfa9 100644
--- a/src/mame/video/maria.h
+++ b/src/mame/video/maria.h
@@ -66,10 +66,10 @@ private:
DECLARE_DEVICE_TYPE(ATARI_MARIA, atari_maria_device)
#define MCFG_MARIA_SCREEN(screen_tag) \
- downcast<atari_maria_device &>(*device).set_screen_tag(("^" screen_tag));
+ downcast<atari_maria_device &>(*device).set_screen_tag(screen_tag);
#define MCFG_MARIA_DMACPU(cpu_tag) \
- downcast<atari_maria_device &>(*device).set_cpu_tag(("^" cpu_tag));
+ downcast<atari_maria_device &>(*device).set_cpu_tag(cpu_tag);
#endif // MAME_VIDEO_MARIA_H
diff --git a/src/mame/video/mb60553.h b/src/mame/video/mb60553.h
index 6de1d4ed662..3f54dd7fc95 100644
--- a/src/mame/video/mb60553.h
+++ b/src/mame/video/mb60553.h
@@ -63,6 +63,6 @@ DECLARE_DEVICE_TYPE(MB60553, mb60553_zooming_tilemap_device)
downcast<mb60553_zooming_tilemap_device &>(*device).set_gfx_region(_region);
#define MCFG_MB60553_GFXDECODE(_gfxtag) \
- downcast<mb60553_zooming_tilemap_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<mb60553_zooming_tilemap_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_MB60533_H
diff --git a/src/mame/video/pc080sn.h b/src/mame/video/pc080sn.h
index 2d2dfd60740..4c429dc7f9b 100644
--- a/src/mame/video/pc080sn.h
+++ b/src/mame/video/pc080sn.h
@@ -85,6 +85,6 @@ DECLARE_DEVICE_TYPE(PC080SN, pc080sn_device)
downcast<pc080sn_device &>(*device).set_dblwidth(_dbl);
#define MCFG_PC080SN_GFXDECODE(_gfxtag) \
- downcast<pc080sn_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<pc080sn_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_PC080SN_H
diff --git a/src/mame/video/pc090oj.h b/src/mame/video/pc090oj.h
index a7b3677506d..ce71c0d8302 100644
--- a/src/mame/video/pc090oj.h
+++ b/src/mame/video/pc090oj.h
@@ -71,9 +71,9 @@ DECLARE_DEVICE_TYPE(PC090OJ, pc090oj_device)
downcast<pc090oj_device &>(*device).set_usebuffer(_use_buf);
#define MCFG_PC090OJ_GFXDECODE(_gfxtag) \
- downcast<pc090oj_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<pc090oj_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_PC090OJ_PALETTE(_palette_tag) \
- downcast<pc090oj_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<pc090oj_device &>(*device).set_palette_tag(_palette_tag);
#endif // MAME_VIDEO_PC090)J_H
diff --git a/src/mame/video/segaic16.h b/src/mame/video/segaic16.h
index 8415c570cc9..d3e2f18263a 100644
--- a/src/mame/video/segaic16.h
+++ b/src/mame/video/segaic16.h
@@ -165,6 +165,6 @@ DECLARE_DEVICE_TYPE(SEGAIC16VID, segaic16_video_device)
MCFG_DEVICE_ADD(_tag, SEGAIC16VID, 0)
#define MCFG_SEGAIC16VID_GFXDECODE(_gfxtag) \
- downcast<segaic16_video_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<segaic16_video_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_SEGAIC16_H
diff --git a/src/mame/video/seta001.h b/src/mame/video/seta001.h
index b83194fad66..5482b7213d0 100644
--- a/src/mame/video/seta001.h
+++ b/src/mame/video/seta001.h
@@ -89,6 +89,6 @@ private:
DECLARE_DEVICE_TYPE(SETA001_SPRITE, seta001_device)
#define MCFG_SETA001_SPRITE_GFXDECODE(_gfxtag) \
- downcast<seta001_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<seta001_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_SETA001_H
diff --git a/src/mame/video/snk68_spr.h b/src/mame/video/snk68_spr.h
index c5573d9e36c..d31bccdacf3 100644
--- a/src/mame/video/snk68_spr.h
+++ b/src/mame/video/snk68_spr.h
@@ -10,7 +10,7 @@
typedef device_delegate<void (int&, int&, int&, int&)> snk68_tile_indirection_delegate;
#define MCFG_SNK68_SPR_GFXDECODE(_gfxtag) \
- downcast<snk68_spr_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<snk68_spr_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_SNK68_SPR_SET_TILE_INDIRECT( _class, _method) \
downcast<snk68_spr_device &>(*device).set_tile_indirect_cb(snk68_tile_indirection_delegate(&_class::_method, #_class "::" #_method, nullptr, (_class *)nullptr));
#define MCFG_SNK68_SPR_NO_PARTIAL \
diff --git a/src/mame/video/tc0080vco.h b/src/mame/video/tc0080vco.h
index 39ebf0e7d5d..8185163ab14 100644
--- a/src/mame/video/tc0080vco.h
+++ b/src/mame/video/tc0080vco.h
@@ -97,6 +97,6 @@ DECLARE_DEVICE_TYPE(TC0080VCO, tc0080vco_device)
downcast<tc0080vco_device &>(*device).set_bgflip_yoffs(_offs);
#define MCFG_TC0080VCO_GFXDECODE(_gfxtag) \
- downcast<tc0080vco_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<tc0080vco_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_TC0080VCO_H
diff --git a/src/mame/video/tc0100scn.h b/src/mame/video/tc0100scn.h
index d8a689a9716..459b992200b 100644
--- a/src/mame/video/tc0100scn.h
+++ b/src/mame/video/tc0100scn.h
@@ -141,9 +141,9 @@ DECLARE_DEVICE_TYPE(TC0100SCN, tc0100scn_device)
downcast<tc0100scn_device &>(*device).set_multiscr_hack(_hack);
#define MCFG_TC0100SCN_GFXDECODE(_gfxtag) \
- downcast<tc0100scn_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<tc0100scn_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_TC0100SCN_PALETTE(_palette_tag) \
- downcast<tc0100scn_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<tc0100scn_device &>(*device).set_palette_tag(_palette_tag);
#endif // MAME_VIDEO_TC0100SCN_H
diff --git a/src/mame/video/tc0110pcr.h b/src/mame/video/tc0110pcr.h
index 42b5efd301a..054a03f5197 100644
--- a/src/mame/video/tc0110pcr.h
+++ b/src/mame/video/tc0110pcr.h
@@ -38,6 +38,6 @@ DECLARE_DEVICE_TYPE(TC0110PCR, tc0110pcr_device)
#define MCFG_TC0110PCR_ADD(_tag) \
MCFG_DEVICE_ADD(_tag, TC0110PCR, 0)
#define MCFG_TC0110PCR_PALETTE(_palette_tag) \
- downcast<tc0110pcr_device &>(*device).set_palette_tag("^" _palette_tag);
+ downcast<tc0110pcr_device &>(*device).set_palette_tag(_palette_tag);
#endif // MAME_VIDEO_TC0110PCR_H
diff --git a/src/mame/video/tc0180vcu.h b/src/mame/video/tc0180vcu.h
index da21205f946..170ded0cbf2 100644
--- a/src/mame/video/tc0180vcu.h
+++ b/src/mame/video/tc0180vcu.h
@@ -70,6 +70,6 @@ DECLARE_DEVICE_TYPE(TC0180VCU, tc0180vcu_device)
downcast<tc0180vcu_device &>(*device).set_tx_colorbase(_color);
#define MCFG_TC0180VCU_GFXDECODE(_gfxtag) \
- downcast<tc0180vcu_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<tc0180vcu_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_TC0180VCU_H
diff --git a/src/mame/video/tc0280grd.h b/src/mame/video/tc0280grd.h
index 5d4841e12e6..65b3a9c5591 100644
--- a/src/mame/video/tc0280grd.h
+++ b/src/mame/video/tc0280grd.h
@@ -57,9 +57,9 @@ DECLARE_DEVICE_TYPE(TC0280GRD, tc0280grd_device)
downcast<tc0280grd_device &>(*device).set_gfx_region(_region);
#define MCFG_TC0280GRD_GFXDECODE(_gfxtag) \
- downcast<tc0280grd_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<tc0280grd_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_TC0430GRW_GFXDECODE(_gfxtag) \
- downcast<tc0280grd_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<tc0280grd_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_TC0280GRD_H
diff --git a/src/mame/video/tc0480scp.h b/src/mame/video/tc0480scp.h
index 9e578de02d8..282f8473a0d 100644
--- a/src/mame/video/tc0480scp.h
+++ b/src/mame/video/tc0480scp.h
@@ -130,6 +130,6 @@ DECLARE_DEVICE_TYPE(TC0480SCP, tc0480scp_device)
downcast<tc0480scp_device &>(*device).set_col_base(_col);
#define MCFG_TC0480SCP_GFXDECODE(_gfxtag) \
- downcast<tc0480scp_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<tc0480scp_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_TC0480SCP_H
diff --git a/src/mame/video/vrender0.h b/src/mame/video/vrender0.h
index 8d2e005c346..5291f311984 100644
--- a/src/mame/video/vrender0.h
+++ b/src/mame/video/vrender0.h
@@ -63,6 +63,6 @@ DECLARE_DEVICE_TYPE(VIDEO_VRENDER0, vr0video_device)
#define MCFG_VIDEO_VRENDER0_CPU(_tag) \
- downcast<vr0video_device &>(*device).set_cpu_tag("^" _tag);
+ downcast<vr0video_device &>(*device).set_cpu_tag(_tag);
#endif // MAME_VIDEO_VRENDER0_H
diff --git a/src/mame/video/vs920a.h b/src/mame/video/vs920a.h
index b32412dc497..0779c5e7891 100644
--- a/src/mame/video/vs920a.h
+++ b/src/mame/video/vs920a.h
@@ -44,6 +44,6 @@ DECLARE_DEVICE_TYPE(VS920A, vs920a_text_tilemap_device)
downcast<vs920a_text_tilemap_device &>(*device).set_gfx_region(_region);
#define MCFG_VS920A_GFXDECODE(_gfxtag) \
- downcast<vs920a_text_tilemap_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<vs920a_text_tilemap_device &>(*device).set_gfxdecode_tag(_gfxtag);
#endif // MAME_VIDEO_VS920A_H
diff --git a/src/mame/video/vsystem_spr.h b/src/mame/video/vsystem_spr.h
index 3d132f63511..8ca15c3693a 100644
--- a/src/mame/video/vsystem_spr.h
+++ b/src/mame/video/vsystem_spr.h
@@ -20,7 +20,7 @@ typedef device_delegate<uint32_t (uint32_t)> vsystem_tile_indirection_delegate;
#define MCFG_VSYSTEM_SPR_SET_TRANSPEN(_transpen) \
downcast<vsystem_spr_device &>(*device).CG10103_set_transpen(_transpen);
#define MCFG_VSYSTEM_SPR_GFXDECODE(_gfxtag) \
- downcast<vsystem_spr_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<vsystem_spr_device &>(*device).set_gfxdecode_tag(_gfxtag);
#define MCFG_VSYSTEM_SPR_SET_OFFSETS(_xoffs, _yoffs) \
downcast<vsystem_spr_device &>(*device).set_offsets(_xoffs,_yoffs);
#define MCFG_VSYSTEM_SPR_SET_PDRAW(_pdraw) \
diff --git a/src/mame/video/vsystem_spr2.h b/src/mame/video/vsystem_spr2.h
index a96ab3264a0..e25e07c0d32 100644
--- a/src/mame/video/vsystem_spr2.h
+++ b/src/mame/video/vsystem_spr2.h
@@ -15,7 +15,7 @@ typedef device_delegate<uint32_t (uint32_t)> vsystem_tile2_indirection_delegate;
#define MCFG_VSYSTEM_SPR2_SET_OFFSETS(_xoffs, _yoffs) \
downcast<vsystem_spr2_device &>(*device).set_offsets(_xoffs,_yoffs);
#define MCFG_VSYSTEM_SPR2_GFXDECODE(_gfxtag) \
- downcast<vsystem_spr2_device &>(*device).set_gfxdecode_tag("^" _gfxtag);
+ downcast<vsystem_spr2_device &>(*device).set_gfxdecode_tag(_gfxtag);
class vsystem_spr2_device : public device_t
{
diff --git a/src/mame/video/vtvideo.h b/src/mame/video/vtvideo.h
index 5752f0bdc70..eee26be8156 100644
--- a/src/mame/video/vtvideo.h
+++ b/src/mame/video/vtvideo.h
@@ -112,7 +112,7 @@ DECLARE_DEVICE_TYPE(RAINBOW_VIDEO, rainbow_video_device)
#define MCFG_VT_SET_SCREEN MCFG_VIDEO_SET_SCREEN
#define MCFG_VT_CHARGEN(_tag) \
- downcast<vt100_video_device &>(*device).set_chargen_tag("^" _tag);
+ downcast<vt100_video_device &>(*device).set_chargen_tag(_tag);
#define MCFG_VT_VIDEO_RAM_CALLBACK(_read) \
devcb = &downcast<vt100_video_device &>(*device).set_ram_rd_callback(DEVCB_##_read);
diff --git a/src/mame/video/zx8301.h b/src/mame/video/zx8301.h
index a8509f536aa..87e8264afd7 100644
--- a/src/mame/video/zx8301.h
+++ b/src/mame/video/zx8301.h
@@ -42,7 +42,7 @@
///*************************************************************************
#define MCFG_ZX8301_CPU(_tag) \
- downcast<zx8301_device &>(*device).set_cpu_tag("^" _tag);
+ downcast<zx8301_device &>(*device).set_cpu_tag(_tag);
#define MCFG_ZX8301_VSYNC_CALLBACK(_write) \
devcb = &downcast<zx8301_device &>(*device).set_vsync_wr_callback(DEVCB_##_write);