Closed mratsim closed 1 week ago
Also it's important to note that some errors are generated even in files with no push
The z_NEQ variable comes from this template: https://github.com/mratsim/constantine/blob/6ca7cbf/constantine/platforms/constant_time/ct_routines.nim#L138-L141
and the top of the file pushes {.inline.}
, which is not applied to templates, and {.raises: [].}
As mentioned in Discord at https://discord.com/channels/371759389889003530/768367394547957761/1250440092208730152
Using the latest
version2-0
branch I have a regression compared to 2.0.4 that leads to backtick of gensym'ed symbols not being translated to X60 as usual due to https://github.com/nim-lang/Nim/pull/22944 being backported.See CI run: https://github.com/mratsim/constantine/actions/runs/9471919674/job/26096274691?pr=393#step:23:47
It seems to also lead to conflicting types using same name variables
https://github.com/mratsim/constantine/actions/runs/9471919674/job/26096274691?pr=393#step:23:13
Reproducing
Note that gcc-14 has issues that might not be backported yet so it's easier to use Clang (https://github.com/nim-lang/Nim/pulls?q=is%3Apr+%22gcc+14%22+is%3Aclosed+ )
Similar bug
If it helps, in the past I used to have those issues in v2.0.4, but only in templates and only with
{.noInit.}
variables.I found 2 workarounds:
Using inject see: https://github.com/mratsim/constantine/pull/346/files#diff-9af16dfbdb13c0086d14ae9290dab7feba9d35fe1e14f3a4f8ca04455aef49b2L68
Unfortunately I tried to minimize the issue to a single file and failed at the time.