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

Bence Kodaj <bence.kodaj at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                URL|https://wandbox.org/permlin |https://godbolt.org/z/6BpK2
                   |k/A9ImqBRe5vyZMFWC          |9

--- Comment #1 from Bence Kodaj <bence.kodaj at gmail dot com> ---
Sorry, there's a typo in the code - here's the fixed version.
Godbolt URL: https://godbolt.org/z/6BpK29

---------------------------
#include <type_traits>

template< typename, template< auto > typename >
struct IsImplementationOf : std::false_type {};

template< template< auto > typename Template, auto Arg >
struct IsImplementationOf< Template< Arg >, Template > : std::true_type {};

template< typename T >
struct X {
    constexpr X( T ) {}
};

template< X > struct Y {};

int main()
{
    static_assert( IsImplementationOf< Y< X(0) >, Y >::value );

    return 0;
}
---------------------------

Reply via email to