[Bug target/80462] New: [avr] Incorrect "warning: uninitialized variable 'xxx' put into program memory area" for identical strings
gjl at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Apr 19 09:35:00 GMT 2017
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80462
Bug ID: 80462
Summary: [avr] Incorrect "warning: uninitialized variable 'xxx'
put into program memory area" for identical strings
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: minor
Priority: P3
Component: target
Assignee: unassigned at gcc dot gnu.org
Reporter: gjl at gcc dot gnu.org
Target Milestone: ---
const __flash char string1[] = "same string";
const __flash char string2[] = "same string";
throws the following incorrect warning when compiled with -Os -Wall
-fmerge-all-constants:
file.c:2:20: warning: uninitialized variable 'string2' put into program memory
area [-Wuninitialized]
const __flash char string2[] = "same string";
^~~~~~~
More information about the Gcc-bugs
mailing list