summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/mconfig.h
diff options
context:
space:
mode:
author Olivier Galibert <galibert@pobox.com>2022-06-16 12:47:52 +0200
committer Olivier Galibert <galibert@pobox.com>2025-04-29 23:06:41 +0200
commit45d4cd52a8194f2ef9e0383cfb2e2a35634af6ff (patch)
tree4e8d8fcb7382a5e9e0bce5ec59939bcfbe67155a /src/emu/mconfig.h
parent5c14bcdfcb4aefb71b5b62387c4ad05dbeb3814e (diff)
full xtal conversionxtal
Diffstat (limited to 'src/emu/mconfig.h')
-rw-r--r--src/emu/mconfig.h20
1 files changed, 4 insertions, 16 deletions
diff --git a/src/emu/mconfig.h b/src/emu/mconfig.h
index c6cacde581f..203c213f649 100644
--- a/src/emu/mconfig.h
+++ b/src/emu/mconfig.h
@@ -180,9 +180,9 @@ public:
m_current_device = &device;
return token(*this, device);
}
- device_t *device_add(const char *tag, device_type type, u32 clock);
+ device_t *device_add(const char *tag, device_type type, const XTAL &clock = XTAL());
template <typename Creator>
- device_t *device_add(const char *tag, Creator &&type, u32 clock)
+ device_t *device_add(const char *tag, Creator &&type, const XTAL &clock = XTAL())
{
return device_add(tag, device_type(type), clock);
}
@@ -196,15 +196,9 @@ public:
add_device(std::move(device), owner.second);
return &result;
}
- template <typename Creator, typename... Params>
- auto device_add(const char *tag, Creator &&type, XTAL clock, Params &&... args)
- {
- clock.validate(std::string("Instantiating device ") + tag);
- return device_add(tag, std::forward<Creator>(type), clock.value(), std::forward<Params>(args)...);
- }
- device_t *device_replace(const char *tag, device_type type, u32 clock);
+ device_t *device_replace(const char *tag, device_type type, const XTAL &clock = XTAL());
template <typename Creator>
- device_t *device_replace(const char *tag, Creator &&type, u32 clock)
+ device_t *device_replace(const char *tag, Creator &&type, const XTAL &clock = XTAL())
{
return device_replace(tag, device_type(type), clock);
}
@@ -218,12 +212,6 @@ public:
replace_device(std::move(device), *std::get<1>(existing), std::get<2>(existing));
return &result;
}
- template <typename Creator, typename... Params>
- auto device_replace(const char *tag, Creator &&type, XTAL clock, Params &&... args)
- {
- clock.validate(std::string("Replacing device ") + tag);
- return device_replace(tag, std::forward<Creator>(type), clock.value(), std::forward<Params>(args)...);
- }
device_t *device_remove(const char *tag);
private: