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

Patrick Palka <ppalka at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
      Known to fail|                            |12.4.0, 13.3.0, 14.2.0,
                   |                            |15.0
      Known to work|                            |8.5.0
   Last reconfirmed|                            |2024-10-16
           Keywords|                            |rejects-valid
             Status|UNCONFIRMED                 |NEW
            Summary|Compiler seems to           |[12/13/14/15 Regression]
                   |incorrectly cache SFINAE    |Compiler seems to
                   |condition evaluation        |incorrectly cache SFINAE
                   |results                     |condition evaluation
                   |                            |results
                 CC|                            |jason at gcc dot gnu.org,
                   |                            |ppalka at gcc dot gnu.org
   Target Milestone|---                         |12.5

--- Comment #2 from Patrick Palka <ppalka at gcc dot gnu.org> ---
Started with r9-6794-gb491c59fb554a7.  Reduced:

template<class T> using void_t = void;

namespace N {
  template<class T> bool f(T *);

  template<class T>
  void_t<decltype(f(T()))> unrelated();
}

template<class T, class = void>
struct hasCustomFunc
{ static const bool value = false; };

template<class T>
struct hasCustomFunc<T, void_t<decltype(f(T()))>>
{ static const bool value = true; };

static_assert(!hasCustomFunc<int*>::value, "");

Reply via email to