https://gcc.gnu.org/bugzilla/show_bug.cgi?id=123734
Bug ID: 123734
Summary: Module example (and others) in ga68.info fails
compilation with error
Product: gcc
Version: 16.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: algol68
Assignee: algol68 at gcc dot gnu.org
Reporter: jpl.algol68 at gmail dot com
Target Milestone: ---
In the ga68.info (found in gcc 16.0.1 20260120 source tree), there is example
of a module in section 2.2.4.
Attempting to compile a version of this is below:
module Trilean =
def
pub mode Tril = int;
pub Tril dontknow = 0, yes = 1, no = 2;
pub prio AND3 = 3, OR3 = 3, XOR3 = 3;
pub op NOT3 = (Tril a) Tril:
(a + 1 | dontknow, no, yes)
fed
compiling via "ga68 -c trilean.a68" yields error message:
trilean.a68:3:5: error: construct beginning with ‘def’ in line 2 followed by an
initialiser series starting in line 3 is an invalid def-part
3 | pub mode Tril = int;
| ^
A related note: many other self-written module attempts fail in similar manner
mentioning "construct beginning ... followed by an initialiser"