This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH, Fortran] PR 32095: Check for using symbols before they are typed


Hi Daniel,

sorry for coming back to your patch that late.

+/* XXX:  Do this with parser-state, for instance?  I'd prefer this as it seems
+   cleaner to me than adding globals at will...  */

Ditto. Thus I like your suggestion. But this is probably something
for a follow-up patch as one should then include also other variables.

+   "GNU Fortran extension:  Symbol '%s' is used before"

There should be only one space after the colon. For consistency, one
probably should change "GNU Fortran extension:" to "Extension". (Though
I would also not mind to have all of them changed to "GNU extension".)


+  /* XXX: Need to check indices for EXPR_VARIABLE / EXPR_SUBSTRING, too.  */

If you are looking for a stupid example: The following gives no error
with -std=f2003. Maybe leave it for now and change it into a FIXME?

subroutine foo(x,y,n)
  implicit none
  character(*) :: y
  character(len=len(y(1:n))) :: x
  integer :: n
end


+      /* XXX: Emit a warning if we add an IMPLICIT type here?  */
I think this is not needed.

Otherwise: OK for the trunk.
Thanks for the patch.

Tobias


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]