parent
3590f0a64a
commit
c1bbfd3cf8
|
@ -1,3 +1,10 @@
|
|||
2004-09-13 Dale Johannesen <dalej@apple.com>
|
||||
|
||||
PR 17408
|
||||
PR 17409
|
||||
* c-decl.c (start_decl): Repair TREE_STATIC for initialized
|
||||
objects declared extern.
|
||||
|
||||
2004-09-14 Paul Brook <paul@codesourcery.com>
|
||||
|
||||
* config/arm/arm.c (arm_expand_prologue): Make args_to_push a
|
||||
|
|
|
@ -3012,8 +3012,11 @@ start_decl (struct c_declarator *declarator, struct c_declspecs *declspecs,
|
|||
TEM may equal DECL or it may be a previous decl of the same name. */
|
||||
tem = pushdecl (decl);
|
||||
|
||||
if (initialized)
|
||||
DECL_EXTERNAL (tem) = 0;
|
||||
if (initialized && DECL_EXTERNAL (tem))
|
||||
{
|
||||
DECL_EXTERNAL (tem) = 0;
|
||||
TREE_STATIC (tem) = 1;
|
||||
}
|
||||
|
||||
return tem;
|
||||
}
|
||||
|
|
|
@ -1,3 +1,7 @@
|
|||
2004-09-13 Dale Johannesen <dalej@apple.com>
|
||||
|
||||
* gcc.c-torture/compile/pr17408.c: New test case.
|
||||
|
||||
2004-09-13 Mark Mitchell <mark@codesourcery.com>
|
||||
|
||||
PR c++/16716
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
/* PRs 17408 and 17409, with different options. */
|
||||
extern int t;
|
||||
extern int t = 0;
|
||||
void f(){t =0;}
|
||||
void g(){h(&t);}
|
Loading…
Reference in New Issue