summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author AJR <ajrhacker@users.noreply.github.com>2018-11-01 08:07:33 -0400
committer AJR <ajrhacker@users.noreply.github.com>2018-11-01 08:07:33 -0400
commit0040df6bf7b49ca76addd81ab5b24c71ca0b0091 (patch)
tree7c9fcd38f64893105c775bfb808ce6172267c98e
parent85111661f5d7acb82a805126f59b89a1a45c5f6e (diff)
v5x.cpp: Using a virtual method doesn't work for this (nw)
-rw-r--r--src/devices/cpu/nec/v5x.cpp14
-rw-r--r--src/devices/cpu/nec/v5x.h7
2 files changed, 10 insertions, 11 deletions
diff --git a/src/devices/cpu/nec/v5x.cpp b/src/devices/cpu/nec/v5x.cpp
index c071aa958b1..533a112a7a4 100644
--- a/src/devices/cpu/nec/v5x.cpp
+++ b/src/devices/cpu/nec/v5x.cpp
@@ -398,8 +398,8 @@ void v50_device::device_add_mconfig(machine_config &config)
m_tcu->out_handler<0>().set(m_icu, FUNC(pic8259_device::ir0_w));
}
-v5x_base_device::v5x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock)
- : v33_base_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(v5x_base_device::internal_port_map), this))
+v5x_base_device::v5x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor port_map)
+ : v33_base_device(mconfig, type, tag, owner, clock, port_map)
, m_tcu(*this, "tcu")
, m_dmau(*this, "dmau")
, m_icu(*this, "icu")
@@ -408,17 +408,17 @@ v5x_base_device::v5x_base_device(const machine_config &mconfig, device_type type
}
v50_device::v50_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
- : v5x_base_device(mconfig, V50, tag, owner, clock)
+ : v5x_base_device(mconfig, V50, tag, owner, clock, address_map_constructor(FUNC(v50_device::internal_port_map), this))
{
}
-v53_device::v53_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
- : v5x_base_device(mconfig, V53, tag, owner, clock)
+v53_device::v53_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock)
+ : v5x_base_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(v53_device::internal_port_map), this))
{
}
-v53_device::v53_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock)
- : v5x_base_device(mconfig, type, tag, owner, clock)
+v53_device::v53_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
+ : v53_device(mconfig, V53, tag, owner, clock)
{
}
diff --git a/src/devices/cpu/nec/v5x.h b/src/devices/cpu/nec/v5x.h
index 25fe7b123b9..6cff7c3bd91 100644
--- a/src/devices/cpu/nec/v5x.h
+++ b/src/devices/cpu/nec/v5x.h
@@ -44,7 +44,7 @@ public:
auto syndet_handler_cb() { return subdevice<v5x_scu_device>("scu")->syndet_handler(); }
protected:
- v5x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock);
+ v5x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor port_map);
// device_interface overrides
virtual void device_add_mconfig(machine_config &config) override;
@@ -55,7 +55,6 @@ protected:
// device_execute_interface overrides
virtual void execute_set_input(int inputnum, int state) override;
- virtual void internal_port_map(address_map &map) = 0;
virtual void install_peripheral_io() = 0;
DECLARE_WRITE8_MEMBER(BSEL_w) {}
@@ -116,7 +115,7 @@ protected:
virtual void device_start() override;
virtual void device_reset() override;
- virtual void internal_port_map(address_map &map) override;
+ void internal_port_map(address_map &map);
virtual void install_peripheral_io() override;
DECLARE_WRITE8_MEMBER(OPCN_w);
@@ -151,7 +150,7 @@ protected:
virtual void device_start() override;
virtual void device_reset() override;
- virtual void internal_port_map(address_map &map) override;
+ void internal_port_map(address_map &map);
virtual void install_peripheral_io() override;
DECLARE_WRITE8_MEMBER(SCTL_w);