Evan Czaplicki
6ba394c9cb
Get rid of experimental code for handling "deriving"
2014-01-20 01:09:50 +01:00
Evan Czaplicki
2a0a0e6e3c
Simplify SourceSyntax.Type AST, making record extension more restrictive as discussed with @maxsnew
2014-01-13 11:01:10 +01:00
Evan Czaplicki
c966776788
Add -W flag to many files, mostly getting rid of dead imports
2014-01-04 10:54:46 +01:00
Evan Czaplicki
83e8bad84f
Add basics of "deriving" for ADTs and type aliases. Only parse it for type aliases at the moment.
2013-12-23 16:51:15 -08:00
Evan Czaplicki
76b2e56981
Add Strings as a primitive in the compiler
2013-10-02 15:56:43 -07:00
Evan Czaplicki
95ec3a822e
Stop using error
when constraining patterns and when instantiating source types
2013-08-25 20:23:49 -07:00
Evan Czaplicki
143547e766
Fix problem with variable shadowing when instantiating aliased types
2013-08-08 15:45:22 -07:00
Evan Czaplicki
a3f62c34c3
Make errors a little bit better when a type alias gets the wrong number of arguments.
2013-08-06 15:43:59 -07:00
Evan Czaplicki
ce527c0c07
Style change
2013-07-31 12:12:57 -07:00
Evan Czaplicki
6ace8a0bf7
Move the definition of the Signal type out of the compiler and into the Signal library
2013-07-29 15:47:48 +02:00
Evan Czaplicki
46cb850570
Whitespace cleanup
2013-07-29 13:23:14 +02:00
Evan Czaplicki
ab41d0c0e8
Take out types that were listed as "builtin"
2013-07-26 21:19:08 +02:00
Evan Czaplicki
760ad905cf
Add record constructors, begin using lists to represent fields in record types to maintain ordering from the source program
2013-07-26 18:20:57 +02:00
Evan Czaplicki
0f85a2fcfa
Resolve type aliases in instantiator
2013-07-26 15:08:04 +02:00
Evan Czaplicki
0681fbe583
Get rid of dead function and give instantiateTypeWithContext a shorter name
2013-07-26 12:22:15 +02:00
Evan Czaplicki
32a331b3b0
Load ADTs into the environment to fix constraint generation for patterns
2013-07-26 12:19:24 +02:00
Evan Czaplicki
ff67c667a0
Get Matrix2D and Signal compiling
2013-07-26 00:33:59 +02:00
Evan Czaplicki
727d708289
Get libraries to compile
2013-07-26 00:19:21 +02:00
Evan Czaplicki
ec8687610f
Move type annotations out of Environment and into the Basics library
2013-07-26 00:06:52 +02:00
Evan Czaplicki
9fe6c9a564
Change functions for creating type variables, distinguish names of different constraint type variables
2013-07-25 18:07:04 +02:00
Evan Czaplicki
642b1f7fcc
Properly handle constrained variables when converting from Src.Type to Type.Type
2013-07-25 17:36:52 +02:00
Evan Czaplicki
4e7ef5f177
Add definitions for functions that act on numbers and comparables
...
This will get moved into Elm code eventually
2013-07-25 14:54:21 +02:00
Evan Czaplicki
82ca695dca
Add support for "number" type which can be either an Int or Float
2013-07-25 01:24:16 +02:00
Evan Czaplicki
802be96e57
Fix issue in which patterns could become too general
2013-07-23 15:32:08 +02:00
Evan Czaplicki
c140d690fc
First draft of cross-module type checking
...
Currently, all top-level types are imported. No alias resolution
happens so you need to use "import open M" atm.
2013-07-21 22:50:48 +02:00
Evan Czaplicki
4dc68acd60
Stop creating types for ADT's, use Constant and Flexible in the right place
2013-07-19 18:01:26 +02:00
Evan Czaplicki
c881bd8ef2
Fix bug in type application when converting SourceSyntax.Type to Type.Type
...
Also get rid of some print statements.
2013-07-18 18:16:54 +02:00
Evan Czaplicki
a3a7b3ef62
Refactor type environment
...
Migrate some functions to Environment.hs, add built-in types like _List
and _Tuple2.
2013-07-17 19:29:27 +02:00
Evan Czaplicki
0ed72056b6
Add pretty printing for type constraints.
...
Convert source-syntax types into type-checker types and print them
with pretty type variables.
Generate constraints for let-expressions using type annotations.
Build test function to turn strings into type constraints.
2013-07-08 16:47:44 +02:00
Evan Czaplicki
b87b84556c
Move the Environment.hs and Fragment.hs files down a directory.
2013-07-07 12:54:05 +02:00
Evan Czaplicki
ca8441ff2f
Continue getting the new type-checker in order.
2013-07-07 12:52:48 +02:00