diff options
author | burnus <burnus@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-02-20 09:22:28 +0000 |
---|---|---|
committer | burnus <burnus@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-02-20 09:22:28 +0000 |
commit | 970a6d2dd99a9298a10f8e961674dcd3000a9831 (patch) | |
tree | 8aaf6a0ab23f614f379ff2a8bd9fe0c0444b6fce /gcc/fortran/trans-decl.c | |
parent | bdeef0b12e355a7c3c20c69ee1adc2eda5228265 (diff) | |
download | gcc-970a6d2dd99a9298a10f8e961674dcd3000a9831.tar.gz |
fortran/
2007-02-20 Tobias Burnus <burnus@net-b.de>
PR fortran/30522
* symbol.c (gfc_add_volatile): Allow to set VOLATILE
attribute for host-associated variables.
* gfortran.h (symbol_attribute): Save namespace
where VOLATILE has been set.
* trans-decl.c (gfc_finish_var_decl): Move variable
declaration to the top.
testsuite/
2007-02-20 Tobias Burnus <burnus@net-b.de>
PR fortran/30522
* gfortran.dg/volatile10.f90: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@122157 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/fortran/trans-decl.c')
-rw-r--r-- | gcc/fortran/trans-decl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/fortran/trans-decl.c b/gcc/fortran/trans-decl.c index 019fbd6bdc2..862958a1a95 100644 --- a/gcc/fortran/trans-decl.c +++ b/gcc/fortran/trans-decl.c @@ -468,6 +468,7 @@ gfc_finish_decl (tree decl, tree init) static void gfc_finish_var_decl (tree decl, gfc_symbol * sym) { + tree new; /* TREE_ADDRESSABLE means the address of this variable is actually needed. This is the equivalent of the TARGET variables. We also need to set this if the variable is passed by reference in a @@ -518,7 +519,6 @@ gfc_finish_var_decl (tree decl, gfc_symbol * sym) if (sym->attr.volatile_) { - tree new; TREE_THIS_VOLATILE (decl) = 1; new = build_qualified_type (TREE_TYPE (decl), TYPE_QUAL_VOLATILE); TREE_TYPE (decl) = new; |