------- Comment #2 from jakub at gcc dot gnu dot org  2008-01-29 17:31 -------
Created an attachment (id=15051)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15051&action=view)
gcc43-pr35017.patch

TREE_READONLY isn't modifiable, so I guess that part is quite clear and I'm
also
pretty sure about the possibility to reference static const vars declared in
the function.
What is more unclear is in what kind of inline functions this should be warned
about.  6.7.4p3 talks about inline definition of a function, is that function
definition with inline keyword in this context (i.e. any non-static inline
function) or is that inline definition in the 6.7.4p6 sense (one where there is
no external definition)?
The attached patch implements the first choice, leaving the original conditions
for current_function_decl in both places would keep the second choice.
Joseph?


-- 


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

Reply via email to