You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
after a painful reduction from the seemingly uncomprehensible CI failure in #18274, I reduced it to this:
Example 1
whentrue:
macro`&`(pattern: staticstring): untyped=discardvar zook: stringvar x: stringlet s = x &"bar"import t12408c # content doesn't matter, can be empty
nim e main.nim
Current Output
Error: cannot evaluate at compile time: zook
Expected Output
works
Example 2
ditto
whentrue:
proc`&`(pattern: staticfloat) =discardvar zook: stringlet s =`&`(zook, "bar")
import t12408c # content doesn't matter, can be empty
Example 3
ditto
whentrue:
procbar(pattern: staticfloat) =discardprocbar(a, b: int) =discardvar gook: intbar(gook, 2)
import t12408c # content doesn't matter, can be empty
seems to affect nimscript only, not VM, in particular this does work:
procbar(pattern: staticfloat) =discardprocbar(a, b: int) =discardstatic:
var gook: intbar(gook, 2)
import t12408c # content doesn't matter, can be empty
EDIT: I now found Imported static[T] proc breaks nimscript #13960, it's most likely the same cause; I'm agnostic whether to close this as duplicate or keep it open as the examples are a bit different (a test should ideally cover both)
The text was updated successfully, but these errors were encountered:
after a painful reduction from the seemingly uncomprehensible CI failure in #18274, I reduced it to this:
Example 1
nim e main.nim
Current Output
Error: cannot evaluate at compile time: zook
Expected Output
works
Example 2
ditto
Example 3
ditto
Additional Information
1.5.1 e80d7ff
no error if you change things eg:
The text was updated successfully, but these errors were encountered: