[J3] [EXTERNAL] Re: Limitations of SELECT RANK?
ondrej at certik.us
Tue Oct 20 17:45:07 EDT 2020
On Tue, Oct 20, 2020, at 3:02 PM, Van Snyder via J3 wrote:
> On Tue, 2020-10-20 at 19:23 +0000, Bill Long via J3 wrote:
> > Or, using the proposed template syntax:
> > template subroutine add(b1, b2, b3) real,intent(inout) :: b1(..) real,intent(in) :: b2(..) real,intent(in) :: b3(..)
> > b1 = b1 + b2 + b3
> > end subroutine add
> If parameterized (or template) modules are done, there's no point to
> doing parameterized (or template) subroutines.
> Without parameterized (or template) modules, it's not possible to
> complete integration of parameterized derived types with type-bound
> procedures. Parameterized (or template) subroutines do not include
> definitions of related (parameterized) types.
Excellent point about how this integrates with derived types. We need to figure that out.
> If we had done parameterized modules in 2003, we wouldn't have done
> parameterized types, or at least not parameterized by kind type
> parameters, and there wouldn't be a problem with integration of types
> and type-bound procedures.
I don't know yet if parametrized modules is the exact way forward (it is one of the alternatives we are investigating in the generics subgroup: https://github.com/j3-fortran/generics/issues/9), but I 100% agree with the overall sentiment, that we need to have a solid plan how to do generics, before we pass/approve individual features that might or might not work well with the overall generics design.
For that reason I decided to put my efforts in the generics subgroup to help Tom (who leads it) to organize us and to figure out a solid plan for generics for 202Y before our next meeting in February. I think we can do that. And that in turn will allow us to judge these 202X proposals to ensure they are compatible and consistent.
More information about the J3