https://gcc.gnu.org/bugzilla/show_bug.cgi?id=25992
Paolo Carlini changed:
What|Removed |Added
Status|ASSIGNED|NEW
Assignee|paolo.carlini at
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=25992
Paolo Carlini changed:
What|Removed |Added
Status|NEW |ASSIGNED
CC|anton.kirill
--- Comment #5 from bangerth at dealii dot org 2006-03-08 05:02 ---
Confirmed. These two lines should behave the same, but don't:
--
extern bool flag;
int main()
{
char* p;
p = (true ? "a" : "lalala" );
p = (flag ? "a" : "lalala" );
}
--
g/x> /home/bangert
--- Comment #3 from pinskia at gcc dot gnu dot org 2006-01-27 13:59 ---
I have not looked into the standard yet but if GCC's warning message is correct
this is valid but deprecated code which allows for a compiler to accept it or
not.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=2
--- Comment #4 from anton dot kirillov at rd-software dot com 2006-01-27
14:20 ---
(In reply to comment #3)
> I have not looked into the standard yet but if GCC's warning message is
> correct
> this is valid but deprecated code which allows for a compiler to accept it or
> not.
>
dep
--- Comment #2 from anton dot kirillov at rd-software dot com 2006-01-27
13:12 ---
(In reply to comment #1)
> earth:~>g++ t.cc -pedantic -Wwrite-strings
> t.cc: In function int main():
> t.cc:5: warning: deprecated conversion from string constant to char*'
>
Conversion from string
--- Comment #1 from pinskia at gcc dot gnu dot org 2006-01-27 12:39 ---
earth:~>g++ t.cc -pedantic -Wwrite-strings
t.cc: In function int main():
t.cc:5: warning: deprecated conversion from string constant to char*'
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25992