GslCore
GslCore copied to clipboard
BUG: variable self reference causes stack overflow
This (admittedly buggy) GSL causes a stack overflow on our production compiler. Please verify of course but pretty sure it's a bug in GslCore
let x = oGAL1
let y = &y ; &x
There is a primitive check to handle the simple case
let x = &x
here: https://github.com/Amyris/GslCore/blob/c9ae9242ebc0b7cad10555370da846e4bbf727b7/src/GslCore/AstTypes.fs#L474
Expanding this active pattern could be a fine place to start to handle this case. It is tricky, though.