Commit Graph

156 Commits

Author SHA1 Message Date
Eric Dobson
df07151cb9 Centralize the definition of the plambda syntax property. 2013-05-28 20:21:57 -07:00
Sam Tobin-Hochstadt
499bcefa1d Register scoped type variables for internal def. annotations.
Closes PR 13793.
2013-05-28 18:03:41 -04:00
Eric Dobson
b9b1eb14ba Minor whitespace fix. 2013-05-25 18:09:47 -07:00
Eric Dobson
01a88f8db1 Make scoped type vars work only for explict Alls and annotations.
Solves major issue disscussed on PR 13586.
Closes PR 13622.
Solves issue when typechecking lambdas with types like (All (a) Any).
Closes PR 13596.
Closes PR 13539.
Closes PR 13703.
2013-05-25 13:01:02 -07:00
Asumu Takikawa
23d39a9968 Fix regression for (begin) and simplify 2013-05-17 00:33:10 -04:00
Asumu Takikawa
d7f29d3636 Avoid doing the 2nd pass twice at the top-level
Thanks to Eric for pointing this out.
2013-05-17 00:02:06 -04:00
Eric Dobson
f332affa5a Massive cleanup of requriements in TR. 2013-05-15 23:18:29 -07:00
Eric Dobson
4fcda73adf Clean up lam-result.
Make drest a list instead of a pair, replace an int-err with a match error
which has source location, and remove static name for rest argument in error
case.
2013-05-15 21:12:54 -07:00
Asumu Takikawa
2c042998b9 Fix tc-toplevel-form for ignored syntax 2013-05-14 15:25:43 -04:00
Asumu Takikawa
f3e6276f9b Make define-type work at top-level
Closes PR 12913
2013-05-13 17:14:22 -04:00
Eric Dobson
2a94ca9030 Cleanup tc-lambda-unit. 2013-05-08 22:59:40 -07:00
Sam Tobin-Hochstadt
a07cdf39ff Remove contract on unit-exported definition. 2013-05-08 15:25:02 -04:00
Eric Dobson
8db95d007a Move tc/send to new file because it doesn't belong in tc-expr-unit. 2013-05-07 09:32:04 -07:00
Eric Dobson
adbc516edf Move tc-literal to seperate file, as it doesn't belong in tc-expr. 2013-05-07 09:32:04 -07:00
Asumu Takikawa
e53b0858c3 Fix printing of tc-any-results in type errors.
In the long run, these error messages should get
simplified so that this printing is not necessary.

Closes PR 13577 and PR 13526
2013-05-03 15:13:18 -04:00
Eric Dobson
7735aa5799 Make structs initialize to constant instead of covariant. 2013-04-27 11:50:57 -07:00
Eric Dobson
154ab046fe Cleanup names-of-struct 2013-04-27 11:21:29 -07:00
Eric Dobson
03e1ffda3e Switch out? to from-typed? as it has the same meaning. 2013-04-25 08:29:25 -07:00
Eric Dobson
62f74cda0e Cleanup tc-app-helper.rkt. 2013-04-24 23:31:12 -07:00
Eric Dobson
11bd5314e2 Cleanup requires in tc-apply. 2013-04-24 23:13:04 -07:00
Eric Dobson
863ac05332 Fix expected type when typechecking map 2013-04-24 20:13:39 -07:00
Eric Dobson
67dd956b6a Don't let map introduce type variables.
Closes PR 13581.
2013-04-24 20:13:39 -07:00
Eric Dobson
a94c449ff1 Small TR fixes. 2013-04-24 18:46:44 -07:00
Eric Dobson
55aba088de Use information of application site, to reduce possible arities.
Closes PR12905.
2013-04-24 18:46:44 -07:00
Vincent St-Amour
16a75761b0 Make TR-generated identifiers have the same name as original identifiers.
Makes error messages nicer, and makes it easier to correlate with source code.
2013-04-04 15:31:51 -04:00
Vincent St-Amour
ff3d785da2 Use locations from typed identifiers for type-generated contracts. 2013-04-04 15:31:51 -04:00
Eric Dobson
76de4d3cca Fix tc-apply to correctly generate expected ValueDots filters.
Closes PR 13649.
2013-04-04 07:45:15 -07:00
Eric Dobson
2b8efd6676 Fix contracts in TR. 2013-04-04 07:43:08 -07:00
Eric Dobson
3d49087ea3 Fix parsing of dotted rest when there is an expected type.
Closes PR 13646.
2013-04-01 22:17:32 -07:00
Eric Dobson
0e42a791a7 Typecheck (lambda args body) as (arg1 -> result). 2013-03-23 13:18:05 -07:00
Eric Dobson
714f667cf1 Add more hacky things to make with-handlers typecheck.
Closes PR12644.
2013-03-13 22:29:41 -07:00
Eric Dobson
6105ce8b20 Check actual args when form looks like for/list. 2013-03-13 21:45:03 -07:00
Eric Dobson
17cb4fd8d0 Make vector-set! type correctly on complicated inputs.
Closes PR13532.
2013-03-11 21:52:11 -07:00
Eric Dobson
1334e8dcc7 Reduce usage of check-below.
This pushes almost all uses of check below into tc-expr and
tc-expr/check. This means that the optimizer sees more precise types
and can make more optimizations.
2013-03-08 09:00:58 -08:00
Eric Dobson
1fd21ef640 Avoid TR internal error, by checking shape of args. 2013-03-08 09:00:10 -08:00
Eric Dobson
df581c3e4f Remove unused argument to tc/rec-lambda/check. 2013-03-08 08:59:57 -08:00
Eric Dobson
d59a600be6 Make kw/opt lambda special checks work with other expected values.
Closes PR13544.
2013-03-06 08:48:14 -08:00
Eric Dobson
9f01d26f98 Cleanup kw/opt lambda annotations. 2013-03-06 08:48:14 -08:00
Eric Dobson
22ef10c544 Fix heterogeneous vector typechecking. 2013-03-04 09:36:56 -08:00
Asumu Takikawa
ef08cc41e7 Enable contract and add a purpose statement 2013-02-26 17:38:05 -05:00
Vincent St-Amour
034d7245a4 Filters for comparisons with inifinity. 2013-02-21 10:49:57 -05:00
Eric Dobson
3c31803c19 Add a simple-Union and Bottom, and have code use them.
Requires splitting out the match expanders from base-abbrev.
2013-02-14 18:24:52 -05:00
Eric Dobson
b4beabc977 Make tc-let do unions correctly. 2013-02-14 18:24:52 -05:00
Vincent St-Amour
568f401bdc Don't special case typechecking of =.
Its type is more useful than the special typing rule.
2013-02-04 14:32:44 -05:00
Eric Dobson
3c02bb1abb Type check with expected type when checking recursive loops.
Closes PR12678.
2013-01-28 16:03:01 -05:00
Sam Tobin-Hochstadt
e75e494e6a Fix contracts and expected computation for tc-any-results. 2013-01-24 23:15:06 -05:00
Eric Dobson
a2f33f17e9 Remove tc-results? and other minor improvements. 2013-01-23 18:15:21 -05:00
Eric Dobson
5a43a5c730 Made tc/exprs check its non final terms with the correct type.
Closes PR12974.
2013-01-23 16:41:09 -05:00
Eric Dobson
05e53a0de5 Add tc-any-results as new result-type. 2013-01-23 16:41:09 -05:00
Eric Dobson
aac25b42c9 Make AnyValues but don't actually start using it yet. 2013-01-23 16:41:09 -05:00