einstein.cpp: Workaround for clang bug (nw)

The stupid compiler seems to believe that a template variable named 'source' should have the type 'const char *', despite being declared otherwise...
This commit is contained in:
AJR 2017-11-19 20:26:24 -05:00
parent a5a8e0cbdb
commit d3f78338ca

View File

@ -95,7 +95,7 @@ public:
DECLARE_WRITE8_MEMBER(reset_w); DECLARE_WRITE8_MEMBER(reset_w);
DECLARE_READ8_MEMBER(rom_r); DECLARE_READ8_MEMBER(rom_r);
DECLARE_WRITE8_MEMBER(rom_w); DECLARE_WRITE8_MEMBER(rom_w);
template <int source> DECLARE_WRITE_LINE_MEMBER(int_w); template <int src> DECLARE_WRITE_LINE_MEMBER(int_w);
DECLARE_READ8_MEMBER(kybint_msk_r); DECLARE_READ8_MEMBER(kybint_msk_r);
DECLARE_WRITE8_MEMBER(kybint_msk_w); DECLARE_WRITE8_MEMBER(kybint_msk_w);
DECLARE_WRITE8_MEMBER(adcint_msk_w); DECLARE_WRITE8_MEMBER(adcint_msk_w);
@ -279,13 +279,13 @@ static const z80_daisy_config einstein_daisy_chain[] =
{ nullptr } { nullptr }
}; };
template <int source> WRITE_LINE_MEMBER( einstein_state::int_w ) template <int src> WRITE_LINE_MEMBER( einstein_state::int_w )
{ {
int old = m_int; int old = m_int;
if (state) if (state)
{ {
m_int |= (1 << source); m_int |= (1 << src);
if (!old) if (!old)
{ {
m_maincpu->set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE); m_maincpu->set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
@ -294,7 +294,7 @@ template <int source> WRITE_LINE_MEMBER( einstein_state::int_w )
} }
else else
{ {
m_int &= ~(1 << source); m_int &= ~(1 << src);
if (old && !m_int) if (old && !m_int)
{ {
m_maincpu->set_input_line(INPUT_LINE_IRQ0, CLEAR_LINE); m_maincpu->set_input_line(INPUT_LINE_IRQ0, CLEAR_LINE);