Ticket #150 (closed defect: fixed)

Opened 8 years ago

Last modified 8 years ago

PANIC in Type.Location

Reported by: erikd Owned by:
Priority: blocker Milestone: 0.1.3
Component: Core Type Checker Version: 0.1.2
Keywords: Cc:



a :: Int
a = 0

b :: Int %r0
  :- Mutable %r0
b = 0

main ()
= do	println $ show b
	b := 1
	println $ show b
	a := 1

Results in a panic:

ddc: PANIC in Type.Location
    dispSourcePos: no source location in TSI SICrushedF 162 (Base.MutableT *150)
    Please report this bug to the maintainers at:
        or by emailing disciple-cafe@googlegroups.com

Change History

Changed 8 years ago by erikd

Test is test/Broken-skip/T150-TypeLocationPanic/Main?.ds.

Changed 8 years ago by benl

I had a look at this, and I think the way source information is handled needs to be refactored.

At the moment, when we encounter an error we have to trace through the graph looking for what went wrong. It'd be better if when we performed unifications etc, we just built up a graph of justifications. We'd write the inferencer code in a way that guarantees that all required information is available, and eliminate a whole class of bugs like this one, and #149.

Changed 8 years ago by benl

  • status changed from new to closed
  • resolution set to fixed
Note: See TracTickets for help on using tickets.