Commit Graph

249 Commits

Author SHA1 Message Date
Stephen Chang
fca145bbd7 start match2, with support for nested matches --- dont use yet 2016-03-29 17:14:47 -04:00
Stephen Chang
ab1703e2d6 refactor match; add match support for built-in lists
- remove some redundant expansions
2016-03-29 13:55:21 -04:00
Stephen Chang
512d3fb378 update bg/README 2016-03-29 12:34:46 -04:00
Stephen Chang
6815bd9127 fix some file extensions for mlish tests 2016-03-28 19:37:23 -04:00
Stephen Chang
2da260d1f9 refactor mlish tests; parallize run-all-mlish-tests somewhat 2016-03-28 19:30:22 -04:00
Stephen Chang
05969628ff add another polyrecur example 2016-03-28 17:51:23 -04:00
Stephen Chang
92b1f8ec45 add implicitqueue tests to polyrecur.mlish 2016-03-28 17:26:30 -04:00
Stephen Chang
5e1d3f1e22 mlish: suppot polymorphic recursion 2016-03-28 17:11:38 -04:00
Stephen Chang
e9a4a9f1dd add bens tests to run-all-mlish 2016-03-23 18:33:19 -04:00
Stephen Chang
cdd169381f Merge branch 'mlish-examples' of bitbucket.org:stchang/macrotypes 2016-03-23 13:31:12 -04:00
Stephen Chang
4320b24267 readme update 2016-03-23 12:15:47 -04:00
Stephen Chang
a6275ff568 add main readme 2016-03-23 12:11:03 -04:00
Stephen Chang
94a286fe7d move old files to old dir 2016-03-23 12:05:51 -04:00
Stephen Chang
06bed29150 add small test to result.mlish 2016-03-23 11:59:24 -04:00
ben
7dca7d4966 [bg] lambda calculus interpreter 2016-03-23 01:25:26 -04:00
ben
05df033790 [bg] huffman trees 2016-03-23 01:25:22 -04:00
ben
04e1cb701f [bg] more lists, sorting, CPS 2016-03-22 21:25:12 -04:00
ben
41968efaea [bg] starter functions 2016-03-21 23:48:57 -04:00
Stephen Chang
ea3ed2a762 add result.mlish to run-all-mlish-tests 2016-03-21 00:17:27 -04:00
AlexKnauth
0bc592240d add read-tree example 2016-03-21 00:07:20 -04:00
AlexKnauth
9332309160 propagate expected type through lambda
fixes https://bitbucket.org/stchang/macrotypes/issues/4
2016-03-18 23:25:44 -04:00
Stephen Chang
6f48690446 define-type-alias supports type constructors 2016-03-18 20:57:02 -04:00
Stephen Chang
4a44e51b80 fix bug using expected type of id constructors, eg nil 2016-03-18 17:11:47 -04:00
Stephen Chang
09d04cd4c0 mlish: clean up cond so else is not handled separately 2016-03-18 12:34:31 -04:00
Stephen Chang
c89aa1be19 fix expected-ty propagation in cond else; closes #3 2016-03-18 11:57:46 -04:00
Stephen Chang
7f593b52c8 add more inst.mlish tests 2016-03-17 19:22:05 -04:00
Stephen Chang
b65c4adc94 use expected type to help infer instantiation of an app 2016-03-17 19:03:02 -04:00
Stephen Chang
47fe5ae232 allow explicit tyvars in fn def: workaround for inferred poly fn type with wrong arg order 2016-03-17 16:44:56 -04:00
Stephen Chang
8369574812 fix stlc+effect; add check-props testing form 2016-03-14 01:29:46 -04:00
Stephen Chang
6a85e06719 fix let to check expected type against body
- other conditionals probably need this fix
2016-03-10 17:09:28 -05:00
AlexKnauth
2e259163aa add find-min/max 2016-03-10 16:35:57 -05:00
Stephen Chang
f4979c9e58 fix mlish tests to use ->/test -- all tests passing 2016-03-10 16:23:00 -05:00
Stephen Chang
b8e3ad1602 fix bug with tyvar computation
- define separate ->/test constructor that computes tyvars
  and -> does not because it may be nested
  (see "try" fn in alex.mlish)
- add alex.mlish tests
- other mlish tests still broken --- need to use ->/text
2016-03-10 16:16:52 -05:00
AlexKnauth
db1da5ae20 implement find example 2016-03-10 14:30:43 -05:00
AlexKnauth
fe494c6ad3 fix another srcloc 2016-03-10 10:26:50 -05:00
AlexKnauth
f19eafcd8f propagate srcloc to check-equal? form 2016-03-10 10:15:24 -05:00
Stephen Chang
5c5f500f39 clean up requires/provides, see other mlish language additions below
- fix bug where recursive tyvar did not have #%type tag
- records
- optional field names in type definitions
- reuse prefixes by default
- list fns
- provide explicit inst (need it for ho poly fns)
- if now allows non-false instead of bool
- small inference fixes
- add rw ocaml tests, ch6, up to "polymorphic variants"
2016-03-10 00:39:01 -05:00
Stephen Chang
dc3767c844 mlish: add nbody test 2016-03-08 16:25:02 -05:00
Stephen Chang
159bd56bf3 add more iterators and matrix tests 2016-03-08 14:50:37 -05:00
Stephen Chang
2066dbc577 mlish: add require/provide, boxes, set!, more iterators
- add tests: fibo, hash, k-nucleotide
2016-03-07 23:54:47 -05:00
Stephen Chang
f5a043b7e6 mlish: add hash, fl prims, str prims, output, and some other prims
- allow begin exprs to have any type (not just unit)
- add fasta test
2016-03-07 00:31:25 -05:00
Stephen Chang
ee6c0c11f7 mlish: add for/list, when, printf, multi expr bodies
- add fannkuch test
2016-03-05 10:12:32 -05:00
Stephen Chang
468cf075d6 mlish: add vectors, sequences, and iteration
- add ary and ack test
- fix bug in uparrow-s (in typecheck.rkt) extra #'
2016-03-04 16:15:14 -05:00
Stephen Chang
1ad357b55e separate out mlish queens test 2016-03-04 14:20:02 -05:00
Stephen Chang
965778d9f0 add mlish tests 2016-03-04 14:15:28 -05:00
Stephen Chang
cd6c8920ab mlish: add concurrency prims and test 2016-03-03 23:38:21 -05:00
Stephen Chang
8b11b0fb60 fix missing clauses check; code cleanup 2016-03-02 17:08:47 -05:00
Stephen Chang
487c8fedc5 mlish: fix define-type and match
- resolves #1
  - define-type-constructor accepts arbitrary extra "info" that is stored
    with the type
    - get-extra-info extras this info
  - define type stores extra info that is essentially a mu type
    containing all variant info
  - match must manually "unfold" this info, ie iso-recursive
- all tests passing
- mlish tests implements full nqueens example
  - no explicit instantiation of polymorphic functions
  - some polymorphic constructors require annotations when no inference possible
    - a lone nil with no other information
  - lambda params require annotations
  - top lvl fns require full signature
2016-03-02 15:34:51 -05:00
Stephen Chang
3839ea51c4 some code cleanup 2016-02-29 15:36:57 -05:00
Stephen Chang
ab9f96efe4 fix match guards and ordering 2016-02-29 15:33:22 -05:00