summaryrefslogtreecommitdiff
path: root/compiler/rename/RnSource.lhs
Commit message (Collapse)AuthorAgeFilesLines
...
* Refactor TcRnDriver, and check exports on hi-boot filessimonpj@microsoft.com2007-03-161-10/+4
| | | | | | | | | | This patch refactors TcRnDriver to make the top-level structure easier to understand. The change was driven by Trac #924, and this patch fixes that bug. When comparing a module against its hs-boot file, we must ensure that the module exports everything that the hs-boot file exports.
* Remove the DocEntity type. Fixes the problem with duplicate error messages atdavve@dtek.chalmers.se2007-01-051-22/+6
| | | | | its root. Also gets rid of the getDeclMainBinder function which isn't needed anylonger.
* HsSyn clean up for indexed typesManuel M T Chakravarty2007-01-051-66/+39
| | | | | | | | | | - This patch cleans up the HsSyn representation of type family declarations. - The new representation is not only less delicate, it also simplified teh code a bit. - I took the opportunity of stream lining the terminology and function names at the same time. - I also updated the description on the wiki at <http://hackage.haskell.org/trac/ghc/wiki/TypeFunctionsSyntax>
* Big tidy-up of deriving codesimonpj@microsoft.com2007-01-021-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | This tidy-up, triggered by Trac #1068, re-factors the way that 'deriving' happens. It took me way longer than I had intended. The main changes, by far are to TcDeriv; everyting else is a minor consequence. While I was at it, I changed the syntax for standalone deriving, so that it goes derive instance Show (T a) (instead of "derive Show for T"). However, there's still an implicit context, generated by the deriving code, and I wonder if it shouldn't really be derive instance (..) => Show (T a) but I have left it simple for now. I also added a function Type.substTyVars, and used it here and there, which led to some one-line changes otherwise unrelated (sorry). Loose ends: * 'deriving Typeable' for indexed data types is still not right * standalone deriving should be documented
* data family declarations are fine without any type argumentsManuel M T Chakravarty2006-12-291-2/+1
|
* Avoid duplicate error report when renaming HsDoc stuffsimonpj@microsoft.com2006-12-291-58/+66
| | | | | | | | | | | | | | | | This patch is a bit of a hack to avoid a duplicate error when checking class C a where op :: a -> a op2 x = x (This is tcfail077) For reasons I don't understand, the decl of op2 generates an HsDeclEntity, and that gives a renamer error which duplicates the (better) one that comes from rnMethodBinds. A better fix might be to get rid of HsDeclEntities altogether.
* Fix handling of family instances in the presense of this doc stuffManuel M T Chakravarty2006-10-221-0/+4
| | | | | | | | | | | | - Not sure whether I do the right thing, because I don't understand the doc stuff. However, the original code was definitely wrong and breaking the renaming of family instance declarations. - The important point is that in data instance T pats = rhs T is *not* a defining occurence of T (similarly as C is not a defining occurence in "instance C Int").
* Bale out before renamer errors are duplicatedsimonpj@microsoft.com2006-10-061-0/+4
| | | | | | | | | With the new Haddock patch, renamer errors can be duplicated; so we want to bale out before doing the Haddock stuff if errors are found. (E.g test mod67 shows this up.)
* Merge Haddock comment support from ghc.haddock -- big patchdavve@dtek.chalmers.se2006-10-051-14/+46
|
* New syntax for stand-alone deriving. Implemented fully.bjorn@bringert.net2006-09-181-5/+5
|
* Renamer part of stand-alone deriving extension.bjorn@bringert.net2006-09-171-1/+19
|
* Fix scoped type variables for expression type signaturessimonpj@microsoft.com2006-10-031-3/+2
| | | | | | | | | | | | | | | | | | I had forgotten to bring scoped type variables into scope at an expression type signature, such as e :: forall s. <type> where 's' should scope over the expression e. Like everything to do with scoped type variables, fixing this took an unreasonable amount of work. I'm sure there must be a better way to achitect this! I updated the user manual too. A test is tc213. It would be good to push this into 6.6.1
* Fixed two bugs concerning faniliesManuel M T Chakravarty2006-09-201-11/+32
| | | | | | | Mon Sep 18 19:34:38 EDT 2006 Manuel M T Chakravarty <chak@cse.unsw.edu.au> * Fixed two bugs concerning fanilies Mon Sep 4 20:59:49 EDT 2006 Manuel M T Chakravarty <chak@cse.unsw.edu.au> * Fixed two bugs concerning fanilies
* Kind and type checking of indexed typesManuel M T Chakravarty2006-09-201-1/+1
| | | | | | | | | | | | Mon Sep 18 18:39:03 EDT 2006 Manuel M T Chakravarty <chak@cse.unsw.edu.au> * Kind and type checking of indexed types Fri Aug 11 16:09:13 EDT 2006 Manuel M T Chakravarty <chak@cse.unsw.edu.au> * Kind and type checking of indexed types - Type checking of kind signatures - Kind and type checking of instances of indexed types - Validity checks for ATs are still *missing* (ie, that the type indexes coincide with the class parameters and that the defined ATs really belong to the class).
* Check for repeated tyvars in AT family declsManuel M T Chakravarty2006-09-181-3/+24
| | | | | Sat Aug 26 19:49:55 EDT 2006 Manuel M T Chakravarty <chak@cse.unsw.edu.au> * Check for repeated tyvars in AT family decls
* Don't lift ATs out of classes and instances before tcManuel M T Chakravarty2006-09-181-19/+12
| | | | | Wed Aug 9 15:31:08 EDT 2006 Manuel M T Chakravarty <chak@cse.unsw.edu.au> * Don't lift ATs out of classes and instances before tc
* Added error checks & fixed bugsManuel M T Chakravarty2006-09-151-11/+28
| | | | | Thu Aug 3 19:29:38 EDT 2006 Manuel M T Chakravarty <chak@cse.unsw.edu.au> * Added error checks & fixed bugs
* Renaming of indexed typesManuel M T Chakravarty2006-09-151-51/+59
| | | | | Tue Aug 1 23:51:38 EDT 2006 Manuel M T Chakravarty <chak@cse.unsw.edu.au> * Renaming of indexed types
* Renaming of kind signatures (rnTySig)Manuel M T Chakravarty2006-09-151-70/+68
| | | | | Tue Aug 1 16:39:51 EDT 2006 Manuel M T Chakravarty <chak@cse.unsw.edu.au> * Renaming of kind signatures (rnTySig)
* Fix migrated AT supportManuel M T Chakravarty2006-09-151-4/+9
| | | | | | | | Wed Jul 26 18:16:25 EDT 2006 Manuel M T Chakravarty <chak@cse.unsw.edu.au> * Fix migrated AT support - Make it compile - Successfully parses and renames simple AT declarations - Should not affect non-AT programs
* Migrate cvs diff from fptools-assoc branchManuel M T Chakravarty2006-09-151-22/+156
| | | | | | | | | Wed Jul 26 17:46:55 EDT 2006 Manuel M T Chakravarty <chak@cse.unsw.edu.au> * Migrate cvs diff from fptools-assoc branch - Syntactic support for associated types - Renamer support for associated types - ATs are only allowed with -fglasgow-exts - Handle ATs in the type and class declaration kinding knot-tying exercise
* Refactoring for valid rule checkingsimonpj@microsoft.com2006-08-171-10/+14
|
* Disable form-checking for rule LHSssimonpj@microsoft.com2006-08-161-12/+21
| | | | | | | | | | Previously we checked the form of the arguments of a RULE lhs, to ensure that they were simple applications. There was no good reason for that, save to prevent you writing LHSs that were unlikely to match. And Don Stewart found he wanted to do something we didn't allow (a section, I think). So I have just disabled the check.
* Remove old FFI syntaxSimon Marlow2006-08-091-4/+4
| | | | See #815
* Deal correctly with infix type constructors in GADT declssimonpj@microsoft.com2006-07-261-7/+11
|
* Make scoped type variables work for default methodssimonpj@microsoft.com2006-06-121-4/+5
| | | | | | | | | | | Consider class C a where op :: forall b. a -> b -> b op = <rhs> Then 'b' should be in scope in <rhs>. I had omitted this case. This patch fixes it.
* Fix bug shown in the mod77 test.Lemmih2006-04-271-21/+17
|
* Reorganisation of the source treeSimon Marlow2006-04-071-0/+722
Most of the other users of the fptools build system have migrated to Cabal, and with the move to darcs we can now flatten the source tree without losing history, so here goes. The main change is that the ghc/ subdir is gone, and most of what it contained is now at the top level. The build system now makes no pretense at being multi-project, it is just the GHC build system. No doubt this will break many things, and there will be a period of instability while we fix the dependencies. A straightforward build should work, but I haven't yet fixed binary/source distributions. Changes to the Building Guide will follow, too.