This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/61135] It seems to be not able to call virtual method of literal object in lambda expression
- From: "daniel.kruegler at googlemail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 10 May 2014 20:32:35 +0000
- Subject: [Bug c++/61135] It seems to be not able to call virtual method of literal object in lambda expression
- Auto-submitted: auto-generated
- References: <bug-61135-4 at http dot gcc dot gnu dot org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=61135
Daniel KrÃgler <daniel.kruegler at googlemail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |daniel.kruegler@googlemail.
| |com
--- Comment #3 from Daniel KrÃgler <daniel.kruegler at googlemail dot com> ---
1) The problem also exists in gcc 4.10 trunk
2) As written, the presented code would be ill-formed anyway. The following
transformed example presents valid code that produces the same ICE:
//-----------------------
struct Base
{
virtual int b() const{return 1;};
};
struct Super:Base{};
int main()
{
constexpr Super s = Super();
[&]{s.b();}();
}
//-----------------------