https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115664

--- Comment #7 from Jonathan Wakely <redi at gcc dot gnu.org> ---
if constexpr (not is_same_v<T, Object>)
  if (dynamic_cast<T*>(this) == nullptr)
    throw Exception("Bad callback");

Reply via email to