[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: gm2 rejecting a constant statement as variable
From: |
Gaius Mulley |
Subject: |
Re: gm2 rejecting a constant statement as variable |
Date: |
Mon, 01 Apr 2024 19:29:23 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) |
Gaius Mulley:
> I've fixed this locally:
>
> $ gm2 constbool2.mod
> constbool2.mod:8:36: error: In program module ‘constbool2’: the procedure
> function ‘ORD’ is being called from within a constant expression and
> therefore the parameter must be a constant, seen expression
> 8 | BitsInUse = ORD(AddressableBits > MaxBits) * MaxBits +
> ORD(AddressableBits <= MaxBits) * AddressableBits;
> | ~~~~~~~~~~~~~~~~^~~~~~~~~
>
> but I've seen this fix needs to be applied to most of the standard
> procedure functions. Once this is done and passes the regression tests
> I'll push the git changes
the checking of constant parameters to standard procedure functions
(when used in a const expression) is now implemented and has been git
pushed,
regards,
Gaius
- Re: gm2 rejecting a constant statement as variable,
Gaius Mulley <=