view gcc/testsuite/g++.dg/concepts/pr93729.C @ 19:2b5abeee2509 default tip

update gcc11
author anatofuz
date Mon, 25 May 2020 07:50:57 +0900
parents
children
line wrap: on
line source

// { dg-do compile { target c++2a } }

// PR c++/93729

struct B
{
  int a:4;
  int b:4;
};

template<typename T>
concept c1
  = requires(T x, void(f)(int &)) { f(x.a); }; // { dg-bogus "cannot bind" }

static_assert(!c1<B>);