Skip to main content
13 events
when toggle format what by license comment
22 hours ago audit First answers
22 hours ago
yesterday history edited Peter Mortensen CC BY-SA 4.0
Brevity.
yesterday history edited Toby Speight CC BY-SA 4.0
added 26 characters in body
yesterday comment added Yakk - Adam Nevraumont Such invalid lookups cause the requires clause to fail; if you can decide "when overloaded we want this to be false" for some concept, then I think you are in good shape.
yesterday comment added Yakk - Adam Nevraumont No, if you have an overloaded x, decltype(&T::x) is a lookup error.
2 days ago comment added Deduplicator Most of the time, that works. Though let's give x a funky type: struct X { int A::* operator&(); };
2 days ago comment added HolyBlackCat @康桓瑋 For member functions, it's easier to call T::x(...); with the right arguments to choose a specific overload, than to know the full function type to cast the pointer to.
Oct 21 at 9:47 comment added 康桓瑋 @HolyBlackCat If it's overloaded, then T::x is also invalid, Isn't it?
Oct 21 at 8:49 comment added HolyBlackCat @Swift-FridayPie If it's overloaded, you won't be able to form a member pointer, unless you cast it to a specific pointer type.
Oct 21 at 8:42 comment added Swift - Friday Pie @HolyBlackCat I think it' a problem only if you have a static and non-static overload, because std::is_member_pointer_v would return true in that case
Oct 21 at 7:14 comment added HolyBlackCat Mhm, how did I not think of this. Though sadly this is harder to pull off for overloaded member functions.
Oct 21 at 7:14 vote accept HolyBlackCat
Oct 21 at 7:11 history answered Raildex CC BY-SA 4.0