From 0ccb23840ef611039874db22896e22f56e2986c8 Mon Sep 17 00:00:00 2001 From: hap Date: Sat, 14 Dec 2024 15:32:02 +0100 Subject: g65sc02: correct constructor --- src/devices/cpu/m6502/g65sc02.cpp | 13 +++++++++---- src/devices/cpu/m6502/g65sc02.h | 9 ++++++--- src/mame/skeleton/textelcomp.cpp | 2 +- 3 files changed, 16 insertions(+), 8 deletions(-) diff --git a/src/devices/cpu/m6502/g65sc02.cpp b/src/devices/cpu/m6502/g65sc02.cpp index 67b3e742363..167247c2999 100644 --- a/src/devices/cpu/m6502/g65sc02.cpp +++ b/src/devices/cpu/m6502/g65sc02.cpp @@ -20,22 +20,27 @@ DEFINE_DEVICE_TYPE(G65SC12, g65sc12_device, "g65sc12", "GTE G65SC12") DEFINE_DEVICE_TYPE(G65SC102, g65sc102_device, "g65sc102", "GTE G65SC102") DEFINE_DEVICE_TYPE(G65SC112, g65sc112_device, "g65sc112", "GTE G65SC112") +g65sc02_device::g65sc02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : + r65c02_device(mconfig, type, tag, owner, clock) +{ +} + g65sc02_device::g65sc02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : - r65c02_device(mconfig, G65SC02, tag, owner, clock) + g65sc02_device(mconfig, G65SC02, tag, owner, clock) { } g65sc12_device::g65sc12_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : - r65c02_device(mconfig, G65SC12, tag, owner, clock) + g65sc02_device(mconfig, G65SC12, tag, owner, clock) { } g65sc102_device::g65sc102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : - r65c02_device(mconfig, G65SC102, tag, owner, clock) + g65sc02_device(mconfig, G65SC102, tag, owner, clock) { } g65sc112_device::g65sc112_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : - r65c02_device(mconfig, G65SC112, tag, owner, clock) + g65sc02_device(mconfig, G65SC112, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/g65sc02.h b/src/devices/cpu/m6502/g65sc02.h index a0004dfefdb..edd24f0f21c 100644 --- a/src/devices/cpu/m6502/g65sc02.h +++ b/src/devices/cpu/m6502/g65sc02.h @@ -16,19 +16,22 @@ class g65sc02_device : public r65c02_device { public: g65sc02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + +protected: + g65sc02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); }; -class g65sc12_device : public r65c02_device { +class g65sc12_device : public g65sc02_device { public: g65sc12_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); }; -class g65sc102_device : public r65c02_device { +class g65sc102_device : public g65sc02_device { public: g65sc102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); }; -class g65sc112_device : public r65c02_device { +class g65sc112_device : public g65sc02_device { public: g65sc112_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); }; diff --git a/src/mame/skeleton/textelcomp.cpp b/src/mame/skeleton/textelcomp.cpp index 44e98f8a1d3..f68dbf0ba1b 100644 --- a/src/mame/skeleton/textelcomp.cpp +++ b/src/mame/skeleton/textelcomp.cpp @@ -328,7 +328,7 @@ void textelcomp_state::textelcomp(machine_config &config) G65SC02(config, m_maincpu, 3.6864_MHz_XTAL / 2); // G65SC02P-2 (clock not verified) m_maincpu->set_addrmap(AS_PROGRAM, &textelcomp_state::mem_map); - INPUT_MERGER_ANY_HIGH(config, "mainirq").output_handler().set_inputline(m_maincpu, g65sc02_device::IRQ_LINE); + INPUT_MERGER_ANY_HIGH(config, "mainirq").output_handler().set_inputline(m_maincpu, G65SC02_IRQ_LINE); via6522_device &via0(R65C22(config, "via0", 3.6864_MHz_XTAL / 2)); // G65SC22P-2 via0.irq_handler().set("mainirq", FUNC(input_merger_device::in_w<0>)); -- cgit v1.2.3