[Bug middle-end/44321] attribute warn_unused_result fails under inlining.

2010-05-29 Thread bonzini at gnu dot org
--- Comment #5 from bonzini at gnu dot org 2010-05-30 06:42 --- Richi, I think we're saying the same thing from two different directions. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44321

[Bug middle-end/44321] attribute warn_unused_result fails under inlining.

2010-05-29 Thread rguenth at gcc dot gnu dot org
--- Comment #4 from rguenth at gcc dot gnu dot org 2010-05-29 17:46 --- (In reply to comment #3) > I don't think this bug is of any use. Unlike nonnull, unused return values do > not trigger undesirable optimizations and (as far as I can tell) cannot > possibly result in miscompilation.

[Bug middle-end/44321] attribute warn_unused_result fails under inlining.

2010-05-29 Thread bonzini at gnu dot org
--- Comment #3 from bonzini at gnu dot org 2010-05-29 17:32 --- I don't think this bug is of any use. Unlike nonnull, unused return values do not trigger undesirable optimizations and (as far as I can tell) cannot possibly result in miscompilation. This bug is indeed about a loophole,

[Bug middle-end/44321] attribute warn_unused_result fails under inlining.

2010-05-29 Thread rguenth at gcc dot gnu dot org
--- Comment #2 from rguenth at gcc dot gnu dot org 2010-05-29 11:40 --- You can add void bar4 (void) { int dummy; dummy = foo (); } so I'm not sure the ignore_value () function call isn't a use. In fact if you externalize that function it is at least a possible use. Which also ra

[Bug middle-end/44321] attribute warn_unused_result fails under inlining.

2010-05-29 Thread davek at gcc dot gnu dot org
--- Comment #1 from davek at gcc dot gnu dot org 2010-05-29 11:33 --- Created an attachment (id=20771) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=20771&action=view) testcase as per initial comment. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44321