public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "gdr at integrable-solutions dot net" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/25316] POD structures can have Date: Thu, 08 Dec 2005 22:25:00 -0000 [thread overview] Message-ID: <20051208222546.31555.qmail@sourceware.org> (raw) In-Reply-To: <bug-25316-1447@http.gcc.gnu.org/bugzilla/> ------- Comment #2 from gdr at integrable-solutions dot net 2005-12-08 22:25 ------- Subject: Re: New: POD structures can have "mrs at apple dot com" <gcc-bugzilla@gcc.gnu.org> writes: | A user reported that this: | | mrs $ cat > t98.c | struct X { | int a, b; | X() : a(0), b(0) {} | }; | | static void f(const char *s, ...); | | int main() | { | X x; | f("foo!", x); | return 0; | } | | works on other C++ compilers (Metroworks), but on gcc: | | mrs $ ./g++ -B./ -c t98.c | t98.c: In function 'int main()': | t98.c:11: warning: cannot pass objects of non-POD type 'struct X' through | '...'; call will abort at runtime | | This, according the a reading of the standard is a POD type, no, really. :-) Are you saying "struct X" is a POD? -- Gaby -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25316
next prev parent reply other threads:[~2005-12-08 22:25 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2005-12-08 20:48 [Bug c++/25316] New: " mrs at apple dot com 2005-12-08 20:51 ` [Bug c++/25316] " mrs at apple dot com 2005-12-08 22:25 ` gdr at integrable-solutions dot net [this message] 2005-12-08 23:53 ` mrs at apple dot com
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=20051208222546.31555.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).