This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [Bug fortran/52846] [F2008] Support submodules - part 3/3
- From: Paul Richard Thomas <paul dot richard dot thomas at gmail dot com>
- To: "Bader, Reinhold" <Reinhold dot Bader at lrz dot de>
- Cc: Toon Moene <toon at moene dot org>, Mikael Morin <mikael dot morin at sfr dot fr>, Damian Rouson <damian at sourceryinstitute dot org>, "fortran at gcc dot gnu dot org" <fortran at gcc dot gnu dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>, "salvatore dot filippone at uniroma2 dot it" <salvatore dot filippone at uniroma2 dot it>
- Date: Tue, 11 Aug 2015 12:27:55 +0200
- Subject: Re: [Bug fortran/52846] [F2008] Support submodules - part 3/3
- Authentication-results: sourceware.org; auth=none
- References: <CAGkQGiJ-HQA97YRC0fSjR4KFxS=7ft8ci6YjYyO7AWGi_md+cw at mail dot gmail dot com> <55B10B58 dot 9000302 at sfr dot fr> <CAGkQGi+NODX-wo+HKOf1V9nD8PHUVdH9OSU_vaDHJct20DP0Tw at mail dot gmail dot com> <00370BD5-507A-42BF-9D59-E868BBAD3C94 at sourceryinstitute dot org> <CAGkQGiJDdTKbBrUYa-wG4iKHM7brF8=sGT=O6-gNgEEmfo0RXQ at mail dot gmail dot com> <55BF4611 dot 70609 at sfr dot fr> <CAGkQGiKMRrkZw0Mqh2UOzKmGhpZ5_ZXMjPhaKYprMr1qSrQkGA at mail dot gmail dot com> <55C8E8C8 dot 8010307 at moene dot org> <e206414882344132af5c82a3d2d9f9ca at BADWLRZ-SW13MB6 dot ads dot mwn dot de>
Dear All,
Has this been occasioned by this thread or have other makes
encountered the same difficulty in implementation?
Cheers
Paul
On 10 August 2015 at 20:57, Bader, Reinhold <Reinhold.Bader@lrz.de> wrote:
> Hello Toon, all else,
>
> a bit unfortunate, in my opinion (I was present at the discussion).
> I've in the meantime taken some effort to implement what the design pattern
> experts might call an "abstract factory with full dependency inversion" as
> a bare-bones framework and have attached an archive with three variants:
>
> * pre_interp contains the code that is presently valid (and indeed compiles fine
> with both gfortran and ifort), but would become invalid due to indirect
> parent module access
> * post_interp contains a variant that uses a helper module (mod_glue) to avoid
> the indirect ancestor use access (if there is a more concise way to do this,
> I'd like to know ... up to now this is the best I can do)
> * post_interp_v2 another shorter variant that pushes the extension types into a submodule
> (with the disadvantage that these types are not really reusable, and
> that the monster module problem is shifted to a monster submodule, or a chain of
> submodules)
> You may need to edit the Makefiles to build.
>
> I would of course like to know how people feel about reintroducing this restriction,
> especially since the only reason given was that ancestor module access and its
> use association overriding host association would confuse users ... which is a
> problem which in my opinion could have been dealt with in a slightly different
> manner without removing the permission for indirect parent module-referencing
> use statements. It is not clear to me whether *implementations* other than
> gfortran have problems with this, though.
>
> More germane to this thread's discussion actually is another interp that was also passed,
> and which appears entirely uncontroversial:
> http://j3-fortran.org/doc/meeting/207/15-209.txt
> It seems to me that this would permit avoiding generation of the .smod files for
> modules that do not specify an separate module procedure interface.
>
> Cheers
> Reinhold
>
>> -----UrsprÃngliche Nachricht-----
>>
>> Although I do not immediately know if this is relevant for *this*
>> debate, J3 passed the following (attached) interpretation on submodules
>> the past week (it still has to go to several mail ballots, but still),
>> overwhelmingly prefering option 3:
>>
>> [attached]
>>
>> Kind regards,
>>
>> --
>> Toon Moene - e-mail: toon@moene.org - phone: +31 346 214290
>> Saturnushof 14, 3738 XG Maartensdijk, The Netherlands
>> At home: http://moene.org/~toon/; weather: http://moene.org/~hirlam/
>> Progress of GNU Fortran: http://gcc.gnu.org/wiki/GFortran#news
--
Outside of a dog, a book is a man's best friend. Inside of a dog it's
too dark to read.
Groucho Marx