diff options
author | couriersud <couriersud@gmx.org> | 2020-05-17 23:41:56 +0200 |
---|---|---|
committer | couriersud <couriersud@gmx.org> | 2020-05-20 07:58:57 +0200 |
commit | 40628bc2693c81501c0b2e08122fa9c25e7f1818 (patch) | |
tree | 6ede7258efe37c32d82713b80c41489c8344f469 /src/devices/machine/netlist.cpp | |
parent | daadbfe6b78b45e91dd405f37d19d5f381f1184b (diff) |
netlist: simplify factory call structure. (nw)
This change will make it a lot easier to add enhanced functionality to
the factory infrastructure.
Using integral constants also improves linking stability.
Diffstat (limited to 'src/devices/machine/netlist.cpp')
-rw-r--r-- | src/devices/machine/netlist.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/devices/machine/netlist.cpp b/src/devices/machine/netlist.cpp index ce13f33dcfe..4d829bdc4d8 100644 --- a/src/devices/machine/netlist.cpp +++ b/src/devices/machine/netlist.cpp @@ -1363,7 +1363,8 @@ void netlist_mame_cpu_device::device_start() void netlist_mame_cpu_device::nl_register_devices(netlist::nlparse_t &parser) const { - parser.factory().add<nld_analog_callback>( "NETDEV_CALLBACK", "-", std::move(PSOURCELOC())); + parser.factory().add<nld_analog_callback>( "NETDEV_CALLBACK", + netlist::factory::properties("-", std::move(PSOURCELOC()))); } uint64_t netlist_mame_cpu_device::execute_clocks_to_cycles(uint64_t clocks) const noexcept @@ -1522,8 +1523,10 @@ void netlist_mame_sound_device::device_start() void netlist_mame_sound_device::nl_register_devices(netlist::nlparse_t &parser) const { - parser.factory().add<nld_sound_out>("NETDEV_SOUND_OUT", "+CHAN", std::move(PSOURCELOC())); - parser.factory().add<nld_sound_in>("NETDEV_SOUND_IN", "-", std::move(PSOURCELOC())); + parser.factory().add<nld_sound_out>("NETDEV_SOUND_OUT", + netlist::factory::properties("+CHAN", std::move(PSOURCELOC()))); + parser.factory().add<nld_sound_in>("NETDEV_SOUND_IN", + netlist::factory::properties("-", std::move(PSOURCELOC()))); } void netlist_mame_sound_device::device_clock_changed() |