Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!rutgers!deimos.cis.ksu.edu!unmvax!brainerd From: brainerd@unmvax.unm.edu (Walt Brainerd) Newsgroups: comp.lang.fortran Subject: Re: dpANS Fortran 8x Summary: I don't see the difference Message-ID: <143@unmvax.unm.edu> Date: 14 Jun 89 14:48:40 GMT References: <135@unmvax.unm.edu> <13937@lanl.gov> Distribution: usa Organization: University of New Mexico at Albuquerque Lines: 46 In article <13937@lanl.gov>, jlg@lanl.gov (Jim Giles) writes: > From article <135@unmvax.unm.edu>, by brainerd@unmvax.unm.edu (Walt Brainerd): > > In article <13934@lanl.gov>, jlg@lanl.gov (Jim Giles) writes: > >> The new pointers _DO_NOT_ provide the functionality of the deleted features. > >> Pointers cannot be used to implement either the RANGE attribute or the > >> IDENTIFY statement. This is because pointers can only alias _contiguous_ > >> memory locations - which is an insignificant subset of the capabilities > >> of the two features that have been removed. > > I have just received the latest version of the X3J3 draft > > and I see nothing that restricts a pointer target to an object > > that is in contiguous storage. [... > > I also have seen the June release of the standard. I see nothing that > _requires_ pointers to be anything but an address with a type attribution. > You did see something that requires it as you convincingly point out in the next paragraph. > > ...] unless I am missing something, the following is legal: > > > > REAL, DIMENSION (100, 100), TARGET :: A > > REAL, DIMENSION (100), POINTER :: P > > . . . > > P => A (50, :) ! P IS AN ALIAS FOR ROW 50 OF A > > In order to implement this, the pointer must actually be (what used to be > called) a 'dope vector'. Exactly right! And the standard requires that this be implemented! > . . . Instead of the above, why not have: > > REAL, DIMENSION (100, 100) :: A > REAL, DIMENSION (100), ALIAS :: P > > P <=> A (50, :) ! P IS AN ALIAS FOR ROW 50 OF A > This is exactly what is there, except for small syntactic changes! <=> is used instead of => ALIAS is used instead of POINTER the TARGET attribute is missing in the declaration of A, which, as has been pointed out, is only there to help the compiler to optimize.