IMHO This program is valid f2008 but gfortran won't compile it. Evidence: cayley[~/Jfh] % cat cplx.f90 ! Works with ifort -stand f95 but not gfortran -std=f2008 implicit none complex:: z = (1,2) print *,z%re print *,z%im end program cayley[~/Jfh] % /usr/bin/gfortran -std=f2008 cplx.f90 cplx.f90:4:12: print *,z%re 1 Error: Unexpected ‘%’ for nonderived-type variable ‘z’ at (1) cplx.f90:5:12: print *,z%im 1 Error: Unexpected ‘%’ for nonderived-type variable ‘z’ at (1) cayley[~/Jfh] % /usr/bin/gfortran -v Using built-in specs. COLLECT_GCC=/usr/bin/gfortran COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-pc-linux-gnu/6.3.1/lto-wrapper Target: x86_64-pc-linux-gnu Configured with: /build/gcc/src/gcc/configure --prefix=/usr --libdir=/usr/lib --libexecdir=/usr/lib --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=https://bugs.archlinux.org/ --enable-languages=c,c++,ada,fortran,go,lto,objc,obj-c++ --enable-shared --enable-threads=posix --enable-libmpx --with-system-zlib --with-isl --enable-__cxa_atexit --disable-libunwind-exceptions --enable-clocale=gnu --disable-libstdcxx-pch --disable-libssp --enable-gnu-unique-object --enable-linker-build-id --enable-lto --enable-plugin --enable-install-libiberty --with-linker-hash-style=gnu --enable-gnu-indirect-function --disable-multilib --disable-werror --enable-checking=release Thread model: posix gcc version 6.3.1 20170109 (GCC) cayley[~/Jfh] %
Dup. *** This bug has been marked as a duplicate of bug 40196 ***
Apologies - I did not find bug 40196 when I was looking for possible duplicates of my bug 82709. On Tue, 24 Oct 2017, dominiq at lps dot ens.fr wrote: > Date: Tue, 24 Oct 2017 23:51:55 +0000 > From: dominiq at lps dot ens.fr <gcc-bugzilla@gcc.gnu.org> > To: John Harper <John.Harper@vuw.ac.nz> > Subject: [Bug fortran/82709] f2008 complex%re and %im not yet implemented > Resent-Date: Wed, 25 Oct 2017 12:52:22 +1300 (NZDT) > Resent-From: <john.harper@vuw.ac.nz> > > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82709 > > Dominique d'Humieres <dominiq at lps dot ens.fr> changed: > > What |Removed |Added > ---------------------------------------------------------------------------- > Status|UNCONFIRMED |RESOLVED > Resolution|--- |DUPLICATE > > --- Comment #1 from Dominique d'Humieres <dominiq at lps dot ens.fr> --- > Dup. > > *** This bug has been marked as a duplicate of bug 40196 *** > > -- > You are receiving this mail because: > You reported the bug. > -- John Harper, School of Mathematics and Statistics Victoria University, PO Box 600, Wellington 6140, New Zealand e-mail john.harper@vuw.ac.nz phone (+64)(4)463 5276 fax (+64)(4)463 5045