gm2
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: String constant in a module


From: Gaius Mulley
Subject: Re: String constant in a module
Date: Mon, 12 Feb 2024 12:50:05 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux)

Philip Munts <phil@munts.net> writes:

> I think this is a severe bug, seen in both Debian GCC 12 and Crosstool-NG GCC 
> 13:
>
> DEFINITION MODULE Foo;
>
>   CONST Bar = "Blech";
>
> END Foo.
>
> IMPLEMENTATION MODULE Foo;
> END Foo.
>
> MODULE test_foo;
>
>   IMPORT Foo;
>
>   FROM STextIO IMPORT WriteString, WriteLn;
>   FROM Foo     IMPORT Bar;
>
> BEGIN
>   WriteString("Bar => ");
>   WriteString(Foo.Bar);
>   WriteLn;
>
>   WriteString("Bar => ");
>   WriteString(Bar);
>   WriteLn;
> END test_foo.
>
> At test program run time, Bar becomes an empty string, with the following 
> result:
>
> Bar =>
> Bar =>

Hi Philip,

many thanks for the bug report, confirmed and I've added a bug report on
bugzilla to track its progress: PR 113889,

regards,
Gaius



reply via email to

[Prev in Thread] Current Thread [Next in Thread]