public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH Fortran] Bug 79866 - diagnostics: typo in "Variable %s at %L of type EVENT_TYPE"
@ 2017-07-01 12:09 Dominique d'Humières
  0 siblings, 0 replies; only message in thread
From: Dominique d'Humières @ 2017-07-01 12:09 UTC (permalink / raw)
  To: Andre Vehreschild; +Cc: gfortran, gcc-patches

If there is no objection, I am planning to commit the following patch as obvious. 

Cheers, 

Dominique

2017-07-01 Dominique d'Humieres <dominiq@lps.ens.fr>

	PR fortran/79866
	* resolve.c (resolve_symbol): Fix typo.

2017-07-01 Dominique d'Humieres <dominiq@lps.ens.fr>

	PR testsuite/79866
	* gfortran.dg/coarray_event_2.f08: New test.

--- ../_clean/gcc/fortran/resolve.c	2017-05-22 19:20:08.000000000 +0200
+++ gcc/fortran/resolve.c	2017-06-29 16:10:27.000000000 +0200
@@ -14525,7 +14525,7 @@ resolve_symbol (gfc_symbol *sym)
       && !sym->attr.codimension && !sym->ts.u.derived->attr.coarray_comp)
     {
       gfc_error ("Variable %s at %L of type EVENT_TYPE or with subcomponent of "
-		 "type LOCK_TYPE must be a coarray", sym->name,
+		 "type EVENT_TYPE must be a coarray", sym->name,
 		 &sym->declared_at);
       return;
     }
--- ../_clean/gcc/testsuite/gfortran.dg/coarray_event_2.f08	1970-01-01 01:00:00.000000000 +0100
+++ gcc/testsuite/gfortran.dg/coarray_event_2.f08	2017-07-01 14:09:18.000000000 +0200
@@ -0,0 +1,13 @@
+! { dg-do compile }
+! { dg-options "-fcoarray=lib -lcaf_single" }
+
+! Check that pr79866 is really fixed.
+
+  use iso_fortran_env
+  type(event_type) :: x ! { dg-error "of type EVENT_TYPE or with subcomponent of type EVENT_TYPE must be a coarray" }
+
+contains
+  subroutine exchange
+    event post (x[1]) ! { dg-error "Syntax error in EVENT POST statement at .1." }
+  end subroutine
+end 

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2017-07-01 12:09 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-01 12:09 [PATCH Fortran] Bug 79866 - diagnostics: typo in "Variable %s at %L of type EVENT_TYPE" Dominique d'Humières

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).