Build fix for function that is not being used by any examples yet
Signature of `make_wren_object()` changed slightly
This commit is contained in:
parent
41692eb0bc
commit
9c147b1a6e
2 changed files with 10 additions and 10 deletions
|
@ -70,13 +70,13 @@ namespace wren {
|
|||
# error "Unsupported compiler"
|
||||
#endif
|
||||
}
|
||||
|
||||
template <typename T, std::size_t S=guess_class_name_impl<T>().size()>
|
||||
static constinit dhandy::bt::string g_class_names = {guess_class_name_impl<T>()};
|
||||
} //namespace detail
|
||||
|
||||
template <typename T, std::size_t S=detail::guess_class_name_impl<T>().size()>
|
||||
constexpr dhandy::bt::string g_guessed_class_name = {detail::guess_class_name_impl<T>()};
|
||||
|
||||
template <typename T>
|
||||
const char* guess_class_name() {
|
||||
return detail::g_class_names<T>.data();
|
||||
constexpr const char* guess_class_name() {
|
||||
return g_guessed_class_name<T>.data();
|
||||
}
|
||||
} //namespace wren
|
||||
|
|
|
@ -48,8 +48,8 @@ namespace wren {
|
|||
T* make_wren_object(VM& vm, ModuleAndName mn, Args&&... args);
|
||||
|
||||
#if defined(WRENPP_WITH_NAME_GUESSING)
|
||||
template <typename T, typename... Args>
|
||||
T* make_wren_object(VM& vm, const char* module, Args&&... args);
|
||||
template <typename T, dhandy::bt::string Mod, typename... Args>
|
||||
T* make_wren_object(VM& vm, Args&&... args);
|
||||
#endif
|
||||
|
||||
template <auto V>
|
||||
|
@ -179,11 +179,11 @@ namespace wren {
|
|||
}
|
||||
|
||||
#if defined(WRENPP_WITH_NAME_GUESSING)
|
||||
template <typename T, typename... Args>
|
||||
inline T* make_wren_object(VM& vm, const char* module, Args&&... args) {
|
||||
template <typename T, dhandy::bt::string Mod, typename... Args>
|
||||
inline T* make_wren_object(VM& vm, Args&&... args) {
|
||||
return make_wren_object<T>(
|
||||
vm,
|
||||
ModuleAndName{module, guess_class_name<T>()},
|
||||
MN<Mod, g_guessed_class_name<T>>,
|
||||
std::forward<Args>(args)...
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue