PR libstdc++/90220 Fix std::any_cast for function pointers
authorJonathan Wakely <jwakely@redhat.com>
Wed, 24 Apr 2019 09:46:07 +0000 (10:46 +0100)
committerJonathan Wakely <redi@gcc.gnu.org>
Wed, 24 Apr 2019 09:46:07 +0000 (10:46 +0100)
commitf9bfdfa2025512c8adb1e280e2df98e0512fbf30
tree84039586f76d44d9032ec02651212a413295dc40
parentde6ae2ce078798024e647b8cc8afeca9d337817a
PR libstdc++/90220 Fix std::any_cast for function pointers

PR libstdc++/90220 (partial)
* include/std/any (any_cast<T>(any*), any_cast<T>(const any*)): Do
not attempt ill-formed static_cast to pointers to non-object types.
* testsuite/20_util/any/misc/any_cast.cc: Test std::any_cast with
function types.

From-SVN: r270538
libstdc++-v3/ChangeLog
libstdc++-v3/include/std/any
libstdc++-v3/testsuite/20_util/any/misc/any_cast.cc