[Bug libstdc++/63329] New: std::bind does not define argument_type
thomas.sanchz at gmail dot com
gcc-bugzilla@gcc.gnu.org
Mon Sep 22 11:30:00 GMT 2014
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63329
Bug ID: 63329
Summary: std::bind does not define argument_type
Product: gcc
Version: 4.9.2
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: libstdc++
Assignee: unassigned at gcc dot gnu.org
Reporter: thomas.sanchz at gmail dot com
Hi,
It looks like the data structure returned by bind does not contain some type
(argument_type) required by std::not1 for instance.
It works with clang + the libc++ on Mac Os X.
#include <functional>
#include <algorithm>
struct Test { bool pred() const { return true; } };
int main(int argc, char *argv[])
{
// works
auto f1 = std::not1(std::mem_fn(&Test::pred));
// works
auto f2 = std::not1(std::mem_fun(&Test::pred));
// does not work: error: no type named ‘argument_type’
auto f3 = std::not1(std::bind(&Test::pred, std::placeholders::_1));
}
Thanks a lot.
More information about the Gcc-bugs
mailing list