public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/42761] New: std::bind doesn't work for simple class types
@ 2010-01-15 18:13 paolo dot carlini at oracle dot com
2010-01-15 18:14 ` [Bug libstdc++/42761] " paolo dot carlini at oracle dot com
` (7 more replies)
0 siblings, 8 replies; 9+ messages in thread
From: paolo dot carlini at oracle dot com @ 2010-01-15 18:13 UTC (permalink / raw)
To: gcc-bugs
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1175 bytes --]
Unfortunately, this very simple example, which we have been discussing for
other reasons, regresses very badly vs tr1. Unfortunately the C++ front-end
doesn't seem ready for a conforming result_of :( Can we prepare a reduced
testcase for Jason?
Maybe he can already tell us whether an error message of the form: "sorry,
unimplemented: unable to determine the declared type of expression
declval<X>()()" points to an issue fixable any time soon...
Otherwise, I'm afraid that for 4.5.0 we have to revert consistently most C++0x
work in <functional>.
///////////////
#include <functional>
struct X {
typedef int result_type;
int operator()() { return 0; }
int operator()() const { return 1; }
};
const auto b = std::bind(X());
b(); // b is const, so must return 1
--
Summary: std::bind doesn't work for simple class types
Product: gcc
Version: 4.5.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: libstdc++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: paolo dot carlini at oracle dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42761
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug libstdc++/42761] std::bind doesn't work for simple class types
2010-01-15 18:13 [Bug libstdc++/42761] New: std::bind doesn't work for simple class types paolo dot carlini at oracle dot com
@ 2010-01-15 18:14 ` paolo dot carlini at oracle dot com
2010-01-15 18:14 ` paolo dot carlini at oracle dot com
` (6 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: paolo dot carlini at oracle dot com @ 2010-01-15 18:14 UTC (permalink / raw)
To: gcc-bugs
--
paolo dot carlini at oracle dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2010-01-15 18:13:58
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42761
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug libstdc++/42761] std::bind doesn't work for simple class types
2010-01-15 18:13 [Bug libstdc++/42761] New: std::bind doesn't work for simple class types paolo dot carlini at oracle dot com
2010-01-15 18:14 ` [Bug libstdc++/42761] " paolo dot carlini at oracle dot com
@ 2010-01-15 18:14 ` paolo dot carlini at oracle dot com
2010-01-15 18:34 ` jwakely dot gcc at gmail dot com
` (5 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: paolo dot carlini at oracle dot com @ 2010-01-15 18:14 UTC (permalink / raw)
To: gcc-bugs
--
paolo dot carlini at oracle dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Severity|normal |blocker
Priority|P3 |P1
Target Milestone|--- |4.5.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42761
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug libstdc++/42761] std::bind doesn't work for simple class types
2010-01-15 18:13 [Bug libstdc++/42761] New: std::bind doesn't work for simple class types paolo dot carlini at oracle dot com
2010-01-15 18:14 ` [Bug libstdc++/42761] " paolo dot carlini at oracle dot com
2010-01-15 18:14 ` paolo dot carlini at oracle dot com
@ 2010-01-15 18:34 ` jwakely dot gcc at gmail dot com
2010-01-15 20:15 ` [Bug c++/42761] " jason at gcc dot gnu dot org
` (4 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: jwakely dot gcc at gmail dot com @ 2010-01-15 18:34 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from jwakely dot gcc at gmail dot com 2010-01-15 18:34 -------
OK, I'll revert it all tomorrow if necessary
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42761
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/42761] std::bind doesn't work for simple class types
2010-01-15 18:13 [Bug libstdc++/42761] New: std::bind doesn't work for simple class types paolo dot carlini at oracle dot com
` (2 preceding siblings ...)
2010-01-15 18:34 ` jwakely dot gcc at gmail dot com
@ 2010-01-15 20:15 ` jason at gcc dot gnu dot org
2010-01-15 20:25 ` paolo dot carlini at oracle dot com
` (3 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: jason at gcc dot gnu dot org @ 2010-01-15 20:15 UTC (permalink / raw)
To: gcc-bugs
--
jason at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |jason at gcc dot gnu dot org
|dot org |
Status|NEW |ASSIGNED
Component|libstdc++ |c++
Last reconfirmed|2010-01-15 18:13:58 |2010-01-15 20:15:03
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42761
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/42761] std::bind doesn't work for simple class types
2010-01-15 18:13 [Bug libstdc++/42761] New: std::bind doesn't work for simple class types paolo dot carlini at oracle dot com
` (3 preceding siblings ...)
2010-01-15 20:15 ` [Bug c++/42761] " jason at gcc dot gnu dot org
@ 2010-01-15 20:25 ` paolo dot carlini at oracle dot com
2010-01-16 15:23 ` jason at gcc dot gnu dot org
` (2 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: paolo dot carlini at oracle dot com @ 2010-01-15 20:25 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from paolo dot carlini at oracle dot com 2010-01-15 20:25 -------
Thanks Jason! If we manage to solve this tough problem, then I know how to
enable also the volatile / const volatile call operators + other improvements
bringing us real close to the WP.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42761
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/42761] std::bind doesn't work for simple class types
2010-01-15 18:13 [Bug libstdc++/42761] New: std::bind doesn't work for simple class types paolo dot carlini at oracle dot com
` (4 preceding siblings ...)
2010-01-15 20:25 ` paolo dot carlini at oracle dot com
@ 2010-01-16 15:23 ` jason at gcc dot gnu dot org
2010-01-16 15:24 ` jason at gcc dot gnu dot org
2010-01-16 17:19 ` redi at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: jason at gcc dot gnu dot org @ 2010-01-16 15:23 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from jason at gcc dot gnu dot org 2010-01-16 15:23 -------
Subject: Bug 42761
Author: jason
Date: Sat Jan 16 15:23:19 2010
New Revision: 155966
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=155966
Log:
PR c++/42761
* semantics.c (finish_decltype_type): Within a template, treat
unresolved CALL_EXPR as dependent.
Added:
trunk/gcc/testsuite/g++.dg/cpp0x/decltype22.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/semantics.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42761
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/42761] std::bind doesn't work for simple class types
2010-01-15 18:13 [Bug libstdc++/42761] New: std::bind doesn't work for simple class types paolo dot carlini at oracle dot com
` (5 preceding siblings ...)
2010-01-16 15:23 ` jason at gcc dot gnu dot org
@ 2010-01-16 15:24 ` jason at gcc dot gnu dot org
2010-01-16 17:19 ` redi at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: jason at gcc dot gnu dot org @ 2010-01-16 15:24 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from jason at gcc dot gnu dot org 2010-01-16 15:24 -------
Fixed.
--
jason at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42761
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/42761] std::bind doesn't work for simple class types
2010-01-15 18:13 [Bug libstdc++/42761] New: std::bind doesn't work for simple class types paolo dot carlini at oracle dot com
` (6 preceding siblings ...)
2010-01-16 15:24 ` jason at gcc dot gnu dot org
@ 2010-01-16 17:19 ` redi at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: redi at gcc dot gnu dot org @ 2010-01-16 17:19 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from redi at gcc dot gnu dot org 2010-01-16 17:19 -------
Thanks, Jason!
Paolo, what's the trick I missed to make the volatile overloads work?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42761
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2010-01-16 17:19 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-01-15 18:13 [Bug libstdc++/42761] New: std::bind doesn't work for simple class types paolo dot carlini at oracle dot com
2010-01-15 18:14 ` [Bug libstdc++/42761] " paolo dot carlini at oracle dot com
2010-01-15 18:14 ` paolo dot carlini at oracle dot com
2010-01-15 18:34 ` jwakely dot gcc at gmail dot com
2010-01-15 20:15 ` [Bug c++/42761] " jason at gcc dot gnu dot org
2010-01-15 20:25 ` paolo dot carlini at oracle dot com
2010-01-16 15:23 ` jason at gcc dot gnu dot org
2010-01-16 15:24 ` jason at gcc dot gnu dot org
2010-01-16 17:19 ` redi at gcc dot gnu dot org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).