https://gcc.gnu.org/bugzilla/show_bug.cgi?id=47030

--- Comment #9 from marco atzeri <marco_atzeri at yahoo dot it> ---
It seems the patch works, just not as I was expecting.

The code allows to export the variables in the common block

--------------------------
$ cat mydll-3.f90
! mydll.f90 --
!     Simple library (to be compiled and linked as DLL/SO)
!
subroutine print

   real :: x
   common /mydata/ x
!GCC$ attributes dllexport :: x

   write(*,*) 'X = ', x

end subroutine print
---------------------------

With gcc-7.3.0 the test case fails as usual

 X =    0.00000000
 In program: X =    1.00000000

with the patch it works.

 X =    1.00000000
 In program: X =    1.00000000

Reply via email to