[PATCH, Fortran] Support for legacy %FILL fields in STRUCTUREs
Fritz Reese
fritzoreese@gmail.com
Mon Jul 31 19:01:00 GMT 2017
All,
Attached is a patch which extends the DEC STRUCTURE support to include
special fields named '%FILL'. These fields generate anonymous
inaccessible components, commonly used in DEC FORTRAN to control
alignment of fields within STRUCTUREs. The patch is fairly
straightforward. The match is performed during parsing in decl.c
(variable_decl) by generating a component with an internal anonymous
name which is an invalid Fortran identifier to replace any components
specified as '%FILL'.
Regtests on x86_64-redhat-linux. OK for trunk?
---
Fritz Reese
>From a94d1aefe608447ff0de469ca90cbcc4942f6168 Mon Sep 17 00:00:00 2001
From: Fritz Reese <Reese-Fritz@zai.com>
Date: Mon, 31 Jul 2017 14:18:25 -0400
Subject: [PATCH] Support for legacy %FILL field in STRUCTUREs.
gcc/fortran/
* decl.c (attr_seen): New static variable.
* decl.c (variable_decl): Match %FILL in STRUCTURE body.
* gfortran.texi: Update documentation.
gcc/testsuite/gfortran.dg/
* dec_structure_18.f90, dec_structure_19.f90, dec_structure_20.f90,
dec_structure_21.f90: New.
---
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dec_fill.patch
Type: text/x-patch
Size: 8310 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20170731/fb363251/attachment.bin>
More information about the Fortran
mailing list