| 348 | enable_if_t<Class::has_alias && std::is_constructible<Alias<Class>, Args...>::value, |
| 349 | int> = 0> |
| 350 | static void execute(Class &cl, const Extra &...extra) { |
| 351 | cl.def( |
| 352 | "__init__", |
| 353 | [](value_and_holder &v_h, Args... args) { |
| 354 | v_h.value_ptr() |
| 355 | = construct_or_initialize<Alias<Class>>(std::forward<Args>(args)...); |
| 356 | }, |
| 357 | is_new_style_constructor(), |
| 358 | extra...); |
| 359 | } |
| 360 | }; |
| 361 | |
| 362 | // Implementation class for py::init(Func) and py::init(Func, AliasFunc) |
nothing calls this directly
no test coverage detected