public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "fang at csl dot cornell dot edu" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/39136] std::mem_fun_ref fails to accept a member function whose second argument with default value Date: Mon, 09 Feb 2009 15:59:00 -0000 [thread overview] Message-ID: <20090209155855.31044.qmail@sourceware.org> (raw) In-Reply-To: <bug-39136-3227@http.gcc.gnu.org/bugzilla/> ------- Comment #3 from fang at csl dot cornell dot edu 2009-02-09 15:58 ------- Subject: Re: std::mem_fun_ref fails to accept a member function whose second argument with default value > ------- Comment #2 from paolo dot carlini at oracle dot com 2009-02-09 09:53 ------- > (In reply to comment #0) >> I'm not sure if this is valid code. However, the standard seems to indicate >> that resize(size_type), is a required member function (or at least interface) >> of std::vector. > > Which standard? To be clear, in the current one, the function is > resize(size_type sz, T c = T()). I'm looking at the current draft, n2798. 23.2.6.2/10-11 [vector.capacity] which lists both forms of resize(). Yes, libstdc++ covers both by using the trailing default argument, but I still can't pass it to mem_fun/mem_fun_ref. Compilation still fails with both -std=c++0x and -std=c++98 with the above test case. (Test case contains a stray line "Test case:" from mis-pasting, my bad.) > Otherwise, the C++0x overloads require concepts (and I think we also have an > open PR about that) Got a PR reference handy? Fang David Fang http://www.csl.cornell.edu/~fang/ http://www.achronix.com/ -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39136
next prev parent reply other threads:[~2009-02-09 15:59 UTC|newest] Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top 2009-02-09 6:50 [Bug libstdc++/39136] New: " fang at csl dot cornell dot edu 2009-02-09 7:39 ` [Bug libstdc++/39136] " fang at csl dot cornell dot edu 2009-02-09 9:53 ` paolo dot carlini at oracle dot com 2009-02-09 15:59 ` fang at csl dot cornell dot edu [this message] 2009-02-09 16:11 ` paolo dot carlini at oracle dot com 2009-02-09 16:47 ` paolo dot carlini at oracle dot com 2009-02-09 17:21 ` fang at csl dot cornell dot edu 2009-02-09 17:26 ` paolo dot carlini at oracle dot com 2009-02-09 17:54 ` fang at csl dot cornell dot edu 2009-02-09 17:59 ` paolo dot carlini at oracle dot com 2009-02-10 22:03 ` pinskia at gcc dot gnu dot org 2009-02-10 22:03 ` pinskia at gcc dot gnu dot org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20090209155855.31044.qmail@sourceware.org \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
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).