This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug middle-end/24015] Wrong code generated when using optimizer


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-09-22 17:06 -------
(In reply to comment #6)
> Hello and thanks for the quick answer! Yes it does! But: I am not getting the
> warning: operation on `data' may be undefined
> 
> when using gcc 3.4.4 and -Wall.

Try at -O0, glibc changes tolower to a macro which causes issues with the warning, I will file another 
bug about that soon.

The short testcase for your issue would be:
#include <ctype.h>
void strtolower(char *data) { while (*data != '\0') *data++ = tolower(*data); }



*** This bug has been marked as a duplicate of 11751 ***

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|WAITING                     |RESOLVED
         Resolution|                            |DUPLICATE


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24015


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]