IRC channel logs

2026-05-26.log

back to list of logs

<wklew>Hi folks, I am getting this error constantly: Wrong type to apply: #<syntax-transformer vec2>
<wklew>In this case vec2 is the chickadee vector constructor. The fix is always to delete the cached .go file, and then things work fine.
<wklew>I get this with syntax all the time lately, and it's very frustrating. AFAICT there is no actual issue with the code, but something to do with compilation.
<rlb>Without knowing anything else, I'd guess that maybe there are macros involved that are changing in ways that affect the .go indirectly. If that's it, you could work around it via more explicit dependency management (e.g. via make and guild compile, or some scheme code, or ...). Right now, guile just doesn't recognize that sort of indirect dependency (e.g. if a macro changes, guile won't do anything about any other files that depend
<rlb>on it).
<ArneBab>define-typed now supports the -> ret style in addition to the structural style: (define-typed (foo a) (real? -> real?) a) -- leaving out the return check is now automatically treated as #f (no check): https://hg.sr.ht/~arnebab/guile-define-typed -- article: https://www.draketo.de/software/guile-define-typed
<ArneBab>Also it now references srfi-253 aka define-checked as alternative.
<ArneBab>wklew: you could try using --fresh-auto-compile -- that helps me when I meddle with things deep inside macros.