public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug c++/31843] -Wformat-nonliteral differs between gcc and g++ [not found] <bug-31843-4@http.gcc.gnu.org/bugzilla/> @ 2012-01-05 0:34 ` paolo.carlini at oracle dot com 2012-01-05 0:34 ` paolo.carlini at oracle dot com 1 sibling, 0 replies; 4+ messages in thread From: paolo.carlini at oracle dot com @ 2012-01-05 0:34 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31843 Paolo Carlini <paolo.carlini at oracle dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC|gcc-bugs at gcc dot gnu.org | Resolution| |FIXED --- Comment #3 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-01-05 00:32:39 UTC --- Fixed in 4.7.0. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/31843] -Wformat-nonliteral differs between gcc and g++ [not found] <bug-31843-4@http.gcc.gnu.org/bugzilla/> 2012-01-05 0:34 ` [Bug c++/31843] -Wformat-nonliteral differs between gcc and g++ paolo.carlini at oracle dot com @ 2012-01-05 0:34 ` paolo.carlini at oracle dot com 1 sibling, 0 replies; 4+ messages in thread From: paolo.carlini at oracle dot com @ 2012-01-05 0:34 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31843 Paolo Carlini <paolo.carlini at oracle dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Target Milestone|--- |4.7.0 ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/31843] New: -Wformat-nonliteral differs between gcc and g++ @ 2007-05-06 7:10 gcc at gaul dot org 2007-05-06 7:10 ` [Bug c++/31843] " gcc at gaul dot org 2010-02-21 1:27 ` manu at gcc dot gnu dot org 0 siblings, 2 replies; 4+ messages in thread From: gcc at gaul dot org @ 2007-05-06 7:10 UTC (permalink / raw) To: gcc-bugs [-- Warning: decoded text below may be mangled, UTF-8 assumed --] [-- Attachment #1: Type: text/plain, Size: 684 bytes --] $ gcc -dumpversion 4.1.1 $ g++ -dumpversion 4.1.1 $ gcc -Wall -Wformat-nonliteral format_nonliteral.c $ g++ -Wall -Wformat-nonliteral format_nonliteral.c format_nonliteral.c: In function int main(int, char**): format_nonliteral.c:10: warning: format not a string literal, argument types not checked -- Summary: -Wformat-nonliteral differs between gcc and g++ Product: gcc Version: 4.1.1 Status: UNCONFIRMED Severity: minor Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: gcc at gaul dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31843 ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/31843] -Wformat-nonliteral differs between gcc and g++ 2007-05-06 7:10 [Bug c++/31843] New: " gcc at gaul dot org @ 2007-05-06 7:10 ` gcc at gaul dot org 2010-02-21 1:27 ` manu at gcc dot gnu dot org 1 sibling, 0 replies; 4+ messages in thread From: gcc at gaul dot org @ 2007-05-06 7:10 UTC (permalink / raw) To: gcc-bugs ------- Comment #1 from gcc at gaul dot org 2007-05-06 08:10 ------- Created an attachment (id=13515) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13515&action=view) -Wformat-nonliteral test case -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31843 ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/31843] -Wformat-nonliteral differs between gcc and g++ 2007-05-06 7:10 [Bug c++/31843] New: " gcc at gaul dot org 2007-05-06 7:10 ` [Bug c++/31843] " gcc at gaul dot org @ 2010-02-21 1:27 ` manu at gcc dot gnu dot org 1 sibling, 0 replies; 4+ messages in thread From: manu at gcc dot gnu dot org @ 2010-02-21 1:27 UTC (permalink / raw) To: gcc-bugs ------- Comment #2 from manu at gcc dot gnu dot org 2010-02-21 01:27 ------- Confirmed. The problem is that constant_value_1 has the following code: if (!init || !TREE_TYPE (init) || (integral_p ? !INTEGRAL_OR_ENUMERATION_TYPE_P (TREE_TYPE (init)) : (!TREE_CONSTANT (init) /* Do not return an aggregate constant (of which string literals are a special case), as we do not want to make inadvertent copies of such entities, and we must be sure that their addresses are the same everywhere. */ => || TREE_CODE (init) == CONSTRUCTOR || TREE_CODE (init) == STRING_CST))) So it does not consider string constant as constant initializers. I think this is probably breaking more than this warning. -- manu at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |manu at gcc dot gnu dot org Status|UNCONFIRMED |NEW Ever Confirmed|0 |1 Last reconfirmed|0000-00-00 00:00:00 |2010-02-21 01:27:20 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31843 ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2012-01-05 0:34 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <bug-31843-4@http.gcc.gnu.org/bugzilla/> 2012-01-05 0:34 ` [Bug c++/31843] -Wformat-nonliteral differs between gcc and g++ paolo.carlini at oracle dot com 2012-01-05 0:34 ` paolo.carlini at oracle dot com 2007-05-06 7:10 [Bug c++/31843] New: " gcc at gaul dot org 2007-05-06 7:10 ` [Bug c++/31843] " gcc at gaul dot org 2010-02-21 1:27 ` manu 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).