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

--- Comment #7 from Harald Anlauf <anlauf at gcc dot gnu.org> ---
(In reply to Steve Kargl from comment #6)
> (In reply to Harald Anlauf from comment #4)
> > 
> > I think we should not allow this extension for modern DO constructs.
> >
> 
> I think it should be disallowed in FORALL as well.  The error
> message in resolve.cc(gfc_resolve_iterator) is guarded with 
> gfc_notify_std (GFC_STD_F95_DEL...).   F95 never allowed REAL 
> iterators and FORALL was introduced in this standard.
> 
> F95, p.114
> 
> R750  forall-triplet-spec  is index-name = subscript : subscript [ : stride]
> R617  subscript            is scalar-int-expr
> R603  stride               is scalar-int-expr
> 
> If it breaks code in the wild, so what?  The code was never correct.

+1

When I specify -std=f2023,

  do j = 1, 0.3
  end do

is already rejected, and

  forall (j = 1:0.3)
  end forall

anyway.  So it is actually a regression...

Reply via email to