plt/racket — pull request #143 by shekari (2012-09-03 09:00:16+00:00)
Title: Make app types have the correct variance

This is a large change so that covariant structures work correctly.

The changes:
* Based on the earlier struct work I did for contracts, because that fixed some bugs in TR's debug contracts.
* Revamp how tc/struct works so that registering the struct-type is separate from registering the bindings of the struct. This is needed so that the variances of struct types can be computed before the bindings are created, as they need to know if the struct is covariant in all of its arguments.
* Revamp how free-vars work. They used to be a hash mapping Symbol/Number to Variance. They are now a more complicated data type that reference a global table for when polymorphic structs are instantiated.
* Change the global table from all covariant (the old way), to the least fixed point of calculating the variance with the table starting at all constant.

Again some tests are failing because of pr13090.