This is the mail archive of the 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]

c/6800: bad warnings for flexible arrays

>Number:         6800
>Category:       c
>Synopsis:       bad warnings for flexible arrays
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri May 24 10:46:01 PDT 2002
>Release:        3.1
Operations, such as __typeof__(f->bar) warn
when the 'bar' member of 'f' is a flexible

See attachment source, it warns:

? gcc -c -o flex.o flex.c
flex.c: In function `bar':
flex.c:8: array initialized from non-constant array expression
flex.c:8: storage size of `b' isn't known
gcc -c -o flex.o flex.c
Shrug... don't use flexible arrays :-)
Content-Type: application/octet-stream; name="flex.c"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="flex.c"


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