Commit 173a960a by Paolo Carlini Committed by Paolo Carlini

re PR c++/79474 (Multiple definitions of user-defined conversion operator cause…

re PR c++/79474 (Multiple definitions of user-defined conversion operator cause ICE (internal compiler error))

2017-10-18  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/79474
	* g++.dg/cpp1y/auto-fn44.C: New.

From-SVN: r253841
parent 697fb2ae
2017-10-18 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/79474
* g++.dg/cpp1y/auto-fn44.C: New.
2017-10-17 Eric Botcazou <ebotcazou@adacore.com>
* gcc.dg/attr-alloc_size-11.c: UnXFAIL for visium-*-*.
......
// PR c++/79474
// { dg-do compile { target c++14 } }
struct Funject
{
operator auto() { return +[](bool b) {return b;}; }
operator auto() { return +[](bool b, bool, bool) {return b;}; } // { dg-error "cannot be overloaded" }
};
Funject fun;
auto bbb = fun(true);
auto bbbb = fun(true, false, true); // { dg-error "no match" }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment