Submitted By: Alexander E. Patrakov
Date: 2006-02-28
Initial Package Version: 4.0.2
Upstream status: Backport
Origin: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24109
Description: fixes compilation of kernel modules that use compound literals.
Upstream log message:
2005-09-29 Jakub Jelinek <jakub@redhat.com>
PR middle-end/24109
* c-decl.c (c_write_global_declarations_1): If any
wrapup_global_declaration_2 call returned true, restart the loop.
old
|
new
|
|
7527 | 7527 | c_write_global_declarations_1 (tree globals) |
7528 | 7528 | { |
7529 | 7529 | tree decl; |
| 7530 | bool reconsider; |
7530 | 7531 | |
7531 | 7532 | /* Process the decls in the order they were written. */ |
7532 | 7533 | for (decl = globals; decl; decl = TREE_CHAIN (decl)) |
… |
… |
|
7545 | 7546 | } |
7546 | 7547 | |
7547 | 7548 | wrapup_global_declaration_1 (decl); |
7548 | | wrapup_global_declaration_2 (decl); |
7549 | | check_global_declaration_1 (decl); |
7550 | 7549 | } |
| 7550 | |
| 7551 | do |
| 7552 | { |
| 7553 | reconsider = false; |
| 7554 | for (decl = globals; decl; decl = TREE_CHAIN (decl)) |
| 7555 | reconsider |= wrapup_global_declaration_2 (decl); |
| 7556 | } |
| 7557 | while (reconsider); |
| 7558 | |
| 7559 | for (decl = globals; decl; decl = TREE_CHAIN (decl)) |
| 7560 | check_global_declaration_1 (decl); |
7551 | 7561 | } |
7552 | 7562 | |
7553 | 7563 | /* A subroutine of c_write_global_declarations Emit debug information for each |