mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-08-31 01:37:57 +00:00
use std::forward in the queuea constructor
This commit is contained in:
@@ -2732,8 +2732,8 @@ EX void drawqueue() {
|
||||
}
|
||||
|
||||
#if HDR
|
||||
template<class T, class... U> T& queuea(PPR prio, U... u) {
|
||||
ptds.push_back(unique_ptr<T>(new T (u...)));
|
||||
template<class T, class... U> T& queuea(PPR prio, U&&... u) {
|
||||
ptds.push_back(unique_ptr<T>(new T (std::forward<U>(u)...)));
|
||||
ptds.back()->prio = prio;
|
||||
return (T&) *ptds.back();
|
||||
}
|
||||
|
Reference in New Issue
Block a user