mirror of
https://github.com/mamedev/mame.git
synced 2024-11-18 10:06:19 +01:00
shut up C++ about missing args to macros, GCC5.1 generates exact same code regardless using -O3 (nw)
This commit is contained in:
parent
9f7f606b5e
commit
958ec9ffe8
3 changed files with 40 additions and 25 deletions
|
@ -22,16 +22,19 @@
|
|||
***********************************************************************/
|
||||
|
||||
#include "discrete.h"
|
||||
/* fix pedantic for C++98, compiler optmizes it out anyway */
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_adder, 1, /* no context */ );
|
||||
#define EVEN_DUMMIES_GET_NAMES int dummy;
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_clamp, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_adder, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_divide, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_clamp, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_gain, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_divide, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_logic_inv, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_gain, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_logic_inv, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP_RESET(dst_bits_decode, 8,
|
||||
int m_count;
|
||||
|
@ -41,17 +44,17 @@ DISCRETE_CLASS_STEP_RESET(dst_bits_decode, 8,
|
|||
int m_last_had_x_time;
|
||||
);
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_logic_and, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_logic_and, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_logic_nand, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_logic_nand, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_logic_or, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_logic_or, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_logic_nor, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_logic_nor, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_logic_xor, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_logic_xor, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_logic_nxor, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_logic_nxor, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP_RESET(dst_logic_dff, 1,
|
||||
int m_last_clk;
|
||||
|
@ -72,7 +75,7 @@ DISCRETE_CLASS_STEP_RESET(dst_logic_shift, 1,
|
|||
UINT8 m_last;
|
||||
);
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_lookup_table, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_lookup_table, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP_RESET(dst_multiplex, 1,
|
||||
int m_size;
|
||||
|
@ -97,11 +100,12 @@ DISCRETE_CLASS_STEP_RESET(dst_samphold, 1,
|
|||
int m_clocktype;
|
||||
);
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_switch, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_switch, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_aswitch, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_aswitch, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(, 1, /* no context */ );
|
||||
//figure this out...
|
||||
//DISCRETE_CLASS_STEP(, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
class DISCRETE_CLASS_NAME(dst_transform): public discrete_base_node, public discrete_step_interface
|
||||
{
|
||||
DISCRETE_CLASS_CONSTRUCTOR(dst_transform, base)
|
||||
|
@ -228,13 +232,13 @@ DISCRETE_CLASS_STEP_RESET(dst_tvca_op_amp, 1,
|
|||
UINT8 m_has_r4;
|
||||
);
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_xtime_buffer, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_xtime_buffer, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_xtime_and, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_xtime_and, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_xtime_or, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_xtime_or, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
DISCRETE_CLASS_STEP(dst_xtime_xor, 1, /* no context */ );
|
||||
DISCRETE_CLASS_STEP(dst_xtime_xor, 1, EVEN_DUMMIES_GET_NAMES /* no context */ );
|
||||
|
||||
|
||||
#endif /* __DISC_WAV_H__ */
|
||||
|
|
|
@ -186,6 +186,7 @@ DISCRETE_CLASS_STEP_RESET(dss_schmitt_osc, 1,
|
|||
|
||||
/* Not yet implemented */
|
||||
DISCRETE_CLASS_STEP_RESET(dss_adsrenv, 1,
|
||||
int dummy; // make C++ happy about empty macro fields
|
||||
//double m_phase;
|
||||
);
|
||||
|
||||
|
|
|
@ -958,7 +958,17 @@ static INPUT_PORTS_START( toaplan1_3b )
|
|||
TOAPLAN_JOY_UDLR_3_BUTTONS( 2 )
|
||||
INPUT_PORTS_END
|
||||
|
||||
#define TOAPLAN1_PLAYER_INPUT( player, button3, options ) \
|
||||
#define TOAPLAN1_PLAYER_INPUT( player, button3 ) \
|
||||
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(player) PORT_8WAY \
|
||||
PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_PLAYER(player) PORT_8WAY \
|
||||
PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(player) PORT_8WAY \
|
||||
PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(player) PORT_8WAY \
|
||||
PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(player) \
|
||||
PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_PLAYER(player) \
|
||||
PORT_BIT( 0x40, IP_ACTIVE_HIGH, button3 ) PORT_PLAYER(player) \
|
||||
PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_UNKNOWN )
|
||||
|
||||
#define TOAPLAN1_PLAYER_INPUT_COCKTAIL( player, button3, options ) \
|
||||
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(player) options PORT_8WAY \
|
||||
PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_PLAYER(player) options PORT_8WAY \
|
||||
PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(player) options PORT_8WAY \
|
||||
|
@ -1264,10 +1274,10 @@ static INPUT_PORTS_START( demonwld )
|
|||
TOAPLAN1_VBLANK_INPUT
|
||||
|
||||
PORT_START("P1")
|
||||
TOAPLAN1_PLAYER_INPUT( 1, IPT_BUTTON3, )
|
||||
TOAPLAN1_PLAYER_INPUT( 1, IPT_BUTTON3 )
|
||||
|
||||
PORT_START("P2")
|
||||
TOAPLAN1_PLAYER_INPUT( 2, IPT_BUTTON3, )
|
||||
TOAPLAN1_PLAYER_INPUT( 2, IPT_BUTTON3 )
|
||||
|
||||
PORT_START("DSWA") /* DSW A */
|
||||
PORT_DIPNAME( 0x01, 0x00, DEF_STR( Unused ) )
|
||||
|
@ -1348,10 +1358,10 @@ static INPUT_PORTS_START( fireshrk )
|
|||
TOAPLAN1_VBLANK_INPUT
|
||||
|
||||
PORT_START("P1")
|
||||
TOAPLAN1_PLAYER_INPUT( 1, IPT_UNKNOWN, )
|
||||
TOAPLAN1_PLAYER_INPUT( 1, IPT_UNKNOWN )
|
||||
|
||||
PORT_START("P2")
|
||||
TOAPLAN1_PLAYER_INPUT( 2, IPT_UNKNOWN, PORT_COCKTAIL )
|
||||
TOAPLAN1_PLAYER_INPUT_COCKTAIL( 2, IPT_UNKNOWN, PORT_COCKTAIL )
|
||||
|
||||
PORT_START("DSWA") /* DSW A */
|
||||
PORT_DIPNAME( 0x01, 0x01, DEF_STR( Cabinet ) )
|
||||
|
@ -1475,7 +1485,7 @@ static INPUT_PORTS_START( samesame2 )
|
|||
PORT_INCLUDE( samesame )
|
||||
|
||||
PORT_MODIFY("P2")
|
||||
TOAPLAN1_PLAYER_INPUT( 2, IPT_UNKNOWN, )
|
||||
TOAPLAN1_PLAYER_INPUT( 2, IPT_UNKNOWN )
|
||||
|
||||
PORT_MODIFY("DSWA") /* DSW A */
|
||||
PORT_DIPNAME( 0x01, 0x00, DEF_STR( Unknown ) ) /* No cocktail */
|
||||
|
|
Loading…
Reference in a new issue