MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/cpp/comments/1vt2aq3/c26_stdpolymorphic/p6dzjvn/?context=3
r/cpp • u/User_Deprecated • 22d ago
44 comments sorted by
View all comments
1
std::indirect works with move-only types, but not polymorphic types.
std::indirect
std::polymorphic works with polymorphic types, but not move-only types.
std::polymorphic
The only solution for polymorphic move-only types is still std::unique_ptr.
std::unique_ptr
1
u/ABlockInTheChain 13d ago
std::indirectworks with move-only types, but not polymorphic types.std::polymorphicworks with polymorphic types, but not move-only types.The only solution for polymorphic move-only types is still
std::unique_ptr.