public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug modula2/112893] New: gm2 fails to detect procedure address actual parameter is incompatible with cardinal formal parameter
@ 2023-12-07  2:23 gaius at gcc dot gnu.org
  2023-12-07  2:24 ` [Bug modula2/112893] " gaius at gcc dot gnu.org
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: gaius at gcc dot gnu.org @ 2023-12-07  2:23 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 112893
           Summary: gm2 fails to detect procedure address actual parameter
                    is incompatible with cardinal formal parameter
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: modula2
          Assignee: gaius at gcc dot gnu.org
          Reporter: gaius at gcc dot gnu.org
  Target Milestone: ---

gm2 silently compiles the following code:

MODULE proccard ;

FROM NumberIO IMPORT WriteCard ;
FROM StrIO IMPORT WriteString, WriteLn ;

PROCEDURE func () : CARDINAL ;
BEGIN
   RETURN 42
END func ;


BEGIN
   WriteString ('the value is: ') ; WriteCard (func, 5) ; WriteLn
END proccard.

whereas it should detect that func is the address of a procedure and this is
incompatible with the cardinal 1st parameter of WriteCard.

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2024-04-20 13:40 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-12-07  2:23 [Bug modula2/112893] New: gm2 fails to detect procedure address actual parameter is incompatible with cardinal formal parameter gaius at gcc dot gnu.org
2023-12-07  2:24 ` [Bug modula2/112893] " gaius at gcc dot gnu.org
2023-12-07  2:26 ` gaius at gcc dot gnu.org
2023-12-07  2:44 ` gaius at gcc dot gnu.org
2023-12-07 12:58 ` gaius at gcc dot gnu.org
2023-12-07 13:11 ` cvs-commit at gcc dot gnu.org
2023-12-07 13:12 ` gaius at gcc dot gnu.org
2023-12-08 14:39 ` gaius at gcc dot gnu.org
2024-04-19 22:39 ` gaius at gcc dot gnu.org
2024-04-20 13:36 ` cvs-commit at gcc dot gnu.org
2024-04-20 13:40 ` gaius at gcc dot gnu.org

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).