Opened 10 years ago

Closed 7 years ago

#83 closed enhancement (invalid)

Look in data definition when checking dangerous vars

Reported by: benl Owned by:
Priority: normal Milestone: 0.3.0
Component: Source Type Inferencer Version:
Keywords: Cc:

Description

data TwoThings r1 r2 r3 a 
      = ThingOne (Int r2)
      | ThingTwo (Maybe r3 b)

wrt the mutability / backtracking problem.

The rule should be at generalisation time, If a region var makes other variables dangerous, then hold it constant unless it already has a mutability constraint. If the user wants it to be mutable, then require them to supply a type signature. Otherwise leave it constant.

For example, if we are to generalise:

 foo :: TwoThings r1 r2 r3

then make r1 and r3 constant, but leave r2 unconstrained.

Change History (4)

comment:1 Changed 9 years ago by benl

  • Summary changed from Look in data definition when checking dangrous vars to Look in data definition when checking dangerous vars

comment:2 Changed 9 years ago by benl

  • Priority changed from blocker to normal

comment:3 Changed 7 years ago by benl

  • Milestone 0.1.5 deleted

Milestone 0.1.5 deleted

comment:4 Changed 7 years ago by benl

  • Milestone set to 0.3.0
  • Resolution set to invalid
  • Status changed from new to closed

pony removal

Note: See TracTickets for help on using tickets.