summaryrefslogtreecommitdiff
path: root/lib/persistence.h
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2024-02-26 22:18:48 +0000
committerDan Goodliffe <dan@randomdan.homeip.net>2024-02-26 22:18:48 +0000
commit52fe8fddaf36fe3c1472fa04c1bed0da848770ac (patch)
tree2b36e11c288559bf323705d11beda81a37edc815 /lib/persistence.h
parentMake terrain deformation test a data test (diff)
downloadilt-52fe8fddaf36fe3c1472fa04c1bed0da848770ac.tar.bz2
ilt-52fe8fddaf36fe3c1472fa04c1bed0da848770ac.tar.xz
ilt-52fe8fddaf36fe3c1472fa04c1bed0da848770ac.zip
Support extra arguments in SelectionV::make_s
Diffstat (limited to 'lib/persistence.h')
-rw-r--r--lib/persistence.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/persistence.h b/lib/persistence.h
index c53ff99..75f578e 100644
--- a/lib/persistence.h
+++ b/lib/persistence.h
@@ -81,11 +81,11 @@ namespace Persistence {
return make_s<SelectionT<T>>(value);
}
- template<typename S>
+ template<typename S, typename... Extra>
[[nodiscard]] static SelectionPtr
- make_s(T & value)
+ make_s(T & value, Extra &&... extra)
{
- return std::make_unique<S>(value);
+ return std::make_unique<S>(value, std::forward<Extra>(extra)...);
}
T & v;