Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0005368OCaml~DO NOT USE (was: OCaml general)public2011-10-04 05:522011-12-13 10:35
Reportertill 
Assigned Togarrigue 
PrioritynormalSeveritycrashReproducibilityalways
StatusclosedResolutionnot fixable 
PlatformOSOS Version
Product Version3.12.1 
Target VersionFixed in Version 
Summary0005368: Stack overflows while type checking programs with long chains of constructors
DescriptionHere's a quick script to generate a program with 100000 elements; on my current machine the compiler segfaults while trying to type check it:

cat > big_list.ml <<EOF
 let big x = [
 $(yes "true;" | head -n 100000)
 ]
EOF

(This bug was triggered on auto-generated code)
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0006219)
garrigue (manager)
2011-12-10 04:06

There is no easy solution to this one.
Basically, the type inference algorithm being recursive, overly deep input leads to stack overflow, and only a major rewrite would solved that.
The error message could be improved, but I'm not sure there would be any benefit: if the list is that long, the reason is clear enough anyway...

- Issue History
Date Modified Username Field Change
2011-10-04 05:52 till New Issue
2011-10-07 11:31 ripoche Note Added: 0006157
2011-10-07 11:37 ripoche Note Deleted: 0006157
2011-12-10 04:04 garrigue Assigned To => garrigue
2011-12-10 04:04 garrigue Status new => assigned
2011-12-10 04:06 garrigue Note Added: 0006219
2011-12-10 04:06 garrigue Status assigned => acknowledged
2011-12-13 10:35 gasche Status acknowledged => closed
2011-12-13 10:35 gasche Resolution open => not fixable
2017-02-23 16:36 doligez Category OCaml general => -OCaml general
2017-03-03 17:55 doligez Category -OCaml general => -(deprecated) general
2017-03-03 18:01 doligez Category -(deprecated) general => ~deprecated (was: OCaml general)
2017-03-06 17:04 doligez Category ~deprecated (was: OCaml general) => ~DO NOT USE (was: OCaml general)


Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker