This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Patch, Fortran] Fix previous patch


Early PING: https://gcc.gnu.org/ml/gcc-patches/2015-01/msg00090.html

Tobias Burnus wrote:
Attached is a regtested patch, which fixes the issue. Additionally, the variable visibility (TREE_PUBLIC) is now depending on the private attribute (copied from the module var generation) and I mark the tree as DECL_NONALIASED. The former I also did for proc-pointers, which is an unrelated patch.

Build and regtested on x86-64-gnu-linux.
OK for the trunk?


Dominique d'Humières wrote:
Compilation with the new patch fails with
../../work/gcc/fortran/trans-decl.c: In function 'void gfc_build_qualified_array(tree, gfc_symbol*)': ../../work/gcc/fortran/trans-decl.c:855:25: error: 'cur_module' was not declared in this scope
     gfc_module_add_decl (cur_module, token);

Which shows that w/o compiling and testing, one (usually) cannot write patches. Solution is to move the declaration up in the file. However, it turned out that that's not sufficient: the pushdecl is required.

Tobias

Le 3 janv. 2015 à 23:30, Tobias Burnus <burnus@net-b.de> a écrit :

Dominique d'Humières wrote:
 From a quick test, with the patch I still see the error with -m32
It helps if one actually adds the decl. The following (still untested) should help. I also marked the token as nonaliasing (it really should!) and added for proc pointers the tree-public optimization.

Tobias
<foo.diff>




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]