Home My Page Projects Code Snippets Project Openings SML/NJ Bugs
Summary Activity Tracker Lists

[#145] Internal exception occurs on bogus annotation instead of typechecking diagnostic

Date:
2015-10-20 14:41
Priority:
3
State:
Closed
Submitted by:
Bug Submitter (webuser)
Assigned to:
David MacQueen (dbm)
Machine Architecture:
None
Operating System:
Generic Unix
Component:
Compiler
Resolution:
Fixed
Severity:
Minor
OS Version:
SML/NJ Version:
110.79
Keywords:
URL:
Transcript (of reproduction):
Standard ML of New Jersey v110.78 [built: Mon Feb 16 08:25:10 2015] - fun f (x : 'a list) = 13 :: x; unexpected exception (bug?) in SML/NJ: Match [nonexhaustive match failure] raised at: ../compiler/Elaborator/types/unify.sml:84.37 ../compiler/Basics/stats/stats.sml:198.40 ../compiler/Elaborator/elaborate/elabmod.sml:1741.65 ../compiler/Elaborator/elaborate/elabmod.sml:1745.59 ../compiler/Basics/stats/stats.sml:198.40 ../compiler/TopLevel/interact/evalloop.sml:44.55
Source (for reproduction):
fun f (x : 'a list) = 13 :: x
Summary:
Internal exception occurs on bogus annotation instead of typechecking diagnostic

Detailed description
An incorrect polymorphic type annotation that should produce typechecking
diagnostics instead results in an uncaught exception.
Additional comments:
The type is properly inferred when the annotation is left off, and diagnostics
are produced when given an incorrect annotation other than 'a list, such as
string list.

Submitted via web form by Mark Laws <mdl@60hz.org>

Comments:

Message  ↓
Date: 2016-08-09 19:28
Sender: John Reppy

Fixed for 110.80

Date: 2015-10-20 15:33
Sender: John Reppy

This bug is also present in 110.79.

Attached Files:

Changes

Field Old Value Date By
status_idOpen2016-08-09 19:28jhr
close_dateNone2016-08-09 19:28jhr
summaryInternal exception occurs on bogus annotation instead of typechecking diagnost2016-08-09 19:28jhr
ResolutionAccepted As Bug2016-08-09 19:28jhr
assigned_tonone2015-10-20 15:33jhr
detailsAn incorrect polymorphic type annotation that should produce typechecking diagnostics instead results in an uncaught exception. Additional comments: The type is properly inferred when the annotation is left off, and diagnostics are produced when given an incorrect annotation other than 'a list, such as string list. Submitted via web form by Mark Laws <mdl@60hz.org> 2015-10-20 15:33jhr
ResolutionNone2015-10-20 15:33jhr
Transcript (of reproduction)Standard ML of New Jersey v110.78 [built: Mon Feb 16 08:25:10 2015] - fun f (x : 'a list) = 13 :: x; unexpected exception (bug?) in SML/NJ: Match [nonexhaustive match failure] raised at: ../compiler/Elaborator/types/unify.sml:84.37 ../compiler/Basics/stats/stats.sml:198.40 ../compiler/Elaborator/elaborate/elabmod.sml:1741.65 ../compiler/Elaborator/elaborate/elabmod.sml:1745.59 ../compiler/Basics/stats/stats.sml:198.40 ../compiler/TopLevel/interact/evalloop.sml:44.552015-10-20 15:33jhr