diff options
Diffstat (limited to 'src/emu/netlist/nl_setup.h')
-rw-r--r-- | src/emu/netlist/nl_setup.h | 90 |
1 files changed, 45 insertions, 45 deletions
diff --git a/src/emu/netlist/nl_setup.h b/src/emu/netlist/nl_setup.h index 627a539dce7..13d456b76e2 100644 --- a/src/emu/netlist/nl_setup.h +++ b/src/emu/netlist/nl_setup.h @@ -19,7 +19,7 @@ #define NET_STR(_x) # _x #define NET_MODEL(_model) \ - netlist.register_model(_model); + netlist.register_model(_model); #define NET_ALIAS(_alias, _name) \ netlist.register_alias(# _alias, # _name); @@ -39,13 +39,13 @@ netlist.register_link(# _name "." # _input, # _output); #define NET_C(_input, _output) \ - netlist.register_link(NET_STR(_input) , NET_STR(_output)); + netlist.register_link(NET_STR(_input) , NET_STR(_output)); #define NETDEV_PARAM(_name, _val) \ netlist.register_param(# _name, _val); #define NETDEV_PARAMI(_name, _param, _val) \ - netlist.register_param(# _name "." # _param, _val); + netlist.register_param(# _name "." # _param, _val); #define NETLIST_NAME(_name) netlist ## _ ## _name @@ -69,30 +69,30 @@ ATTR_COLD void NETLIST_NAME(_name)(netlist_setup_t &netlist) \ class netlist_setup_t { - NETLIST_PREVENT_COPYING(netlist_setup_t) + NETLIST_PREVENT_COPYING(netlist_setup_t) public: - struct link_t - { - link_t() { } - // Copy constructor - link_t(const link_t &from) - { - e1 = from.e1; - e2 = from.e2; - } - - link_t(const pstring &ae1, const pstring &ae2) - { - e1 = ae1; - e2 = ae2; - } - pstring e1; - pstring e2; - - bool operator==(const link_t &rhs) const { return (e1 == rhs.e1) && (e2 == rhs.e2); } - link_t &operator=(const link_t &rhs) { e1 = rhs.e1; e2 = rhs.e2; return *this; } - }; + struct link_t + { + link_t() { } + // Copy constructor + link_t(const link_t &from) + { + e1 = from.e1; + e2 = from.e2; + } + + link_t(const pstring &ae1, const pstring &ae2) + { + e1 = ae1; + e2 = ae2; + } + pstring e1; + pstring e2; + + bool operator==(const link_t &rhs) const { return (e1 == rhs.e1) && (e2 == rhs.e2); } + link_t &operator=(const link_t &rhs) { e1 = rhs.e1; e2 = rhs.e2; return *this; } + }; typedef tagmap_t<pstring, 393> tagmap_nstring_t; typedef tagmap_t<netlist_param_t *, 393> tagmap_param_t; @@ -105,29 +105,29 @@ public: void init(); netlist_base_t &netlist() { return m_netlist; } - const netlist_base_t &netlist() const { return m_netlist; } + const netlist_base_t &netlist() const { return m_netlist; } netlist_factory &factory() { return m_factory; } netlist_device_t *register_dev(netlist_device_t *dev, const pstring &name); void remove_dev(const pstring &name); - void register_model(const pstring &model); - void register_alias(const pstring &alias, const pstring &out); - void register_link(const pstring &sin, const pstring &sout); - void register_param(const pstring ¶m, const pstring &value); - void register_param(const pstring ¶m, const double value); + void register_model(const pstring &model); + void register_alias(const pstring &alias, const pstring &out); + void register_link(const pstring &sin, const pstring &sout); + void register_param(const pstring ¶m, const pstring &value); + void register_param(const pstring ¶m, const double value); - void register_object(netlist_device_t &dev, netlist_core_device_t &upd_dev, const pstring &name, netlist_object_t &obj, netlist_input_t::state_e state); - void connect(netlist_core_terminal_t &t1, netlist_core_terminal_t &t2); + void register_object(netlist_device_t &dev, netlist_core_device_t &upd_dev, const pstring &name, netlist_object_t &obj, netlist_input_t::state_e state); + void connect(netlist_core_terminal_t &t1, netlist_core_terminal_t &t2); - netlist_core_terminal_t *find_terminal(const pstring &outname_in, bool required = true); - netlist_core_terminal_t *find_terminal(const pstring &outname_in, netlist_object_t::type_t atype, bool required = true); + netlist_core_terminal_t *find_terminal(const pstring &outname_in, bool required = true); + netlist_core_terminal_t *find_terminal(const pstring &outname_in, netlist_object_t::type_t atype, bool required = true); - netlist_param_t *find_param(const pstring ¶m_in, bool required = true); + netlist_param_t *find_param(const pstring ¶m_in, bool required = true); - void parse(const char *buf); + void parse(const char *buf); - void start_devices(); + void start_devices(); void resolve_inputs(); /* not ideal, but needed for save_state */ @@ -144,21 +144,21 @@ private: tagmap_nstring_t m_alias; tagmap_param_t m_params; tagmap_link_t m_links; - tagmap_nstring_t m_params_temp; + tagmap_nstring_t m_params_temp; - netlist_factory m_factory; + netlist_factory m_factory; - netlist_list_t<pstring> m_models; + netlist_list_t<pstring> m_models; int m_proxy_cnt; void connect_terminals(netlist_core_terminal_t &in, netlist_core_terminal_t &out); void connect_input_output(netlist_input_t &in, netlist_output_t &out); - void connect_terminal_output(netlist_terminal_t &in, netlist_output_t &out); - void connect_terminal_input(netlist_terminal_t &term, netlist_input_t &inp); + void connect_terminal_output(netlist_terminal_t &in, netlist_output_t &out); + void connect_terminal_input(netlist_terminal_t &term, netlist_input_t &inp); - // helpers - pstring objtype_as_astr(netlist_object_t &in); + // helpers + pstring objtype_as_astr(netlist_object_t &in); const pstring resolve_alias(const pstring &name) const; }; |