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
Preamble: this is probably one of the most pressing limitations of our runtime. It requires some interpreter work, but should be generally accessible to anyone interested.
List.map causes a stack overflow when run in Debug mode, but not when running in Release mode
After running some tests @StachuDotNet found that 348 is the threshold
The tests pass in CI but fail when run locally, indicating that something is different between Release and Debug builds
Potential reasons for this issue:
Bad implementation of List.map
let map (list: List<'a>) (fn: 'a -> 'b) : List<'b> =
(PACKAGE.Darklang.Stdlib.List.fold list [] (fun acc elem ->
PACKAGE.Darklang.Stdlib.List.push_v0 acc (fn elem)))
|> PACKAGE.Darklang.Stdlib.List.reverse
An issue with our interpreter
The text was updated successfully, but these errors were encountered:
StachuDotNet
changed the title
List.map Causes Stack Overflow Error on Large Lists
Bug: List.map Causes Stack Overflow Error on Large Lists
Jan 9, 2024
Preamble: this is probably one of the most pressing limitations of our runtime. It requires some interpreter work, but should be generally accessible to anyone interested.
List.map causes a stack overflow when run in Debug mode, but not when running in Release mode
Code to reproduce the issue:
After running some tests @StachuDotNet found that 348 is the threshold
The tests pass in CI but fail when run locally, indicating that something is different between Release and Debug builds
Potential reasons for this issue:
The text was updated successfully, but these errors were encountered: