summaryrefslogtreecommitdiff
path: root/utils/ext-core
Commit message (Collapse)AuthorAgeFilesLines
* Remove ext-coreIan Lynagh2009-11-0832-5477/+0
| | | | | It is now a separately maintained package, available from hackage: http://hackage.haskell.org/package/extcore
* Under utils/ext-core, update README to mention that ext-core is now on HackageTim Chevalier2009-09-271-0/+9
|
* Put "%expect 0" directives in the .y filesIan Lynagh2009-06-081-0/+1
| | | | | With the exception of GHC's main Parser.y(.pp), which has 2 reduce/reduce conflicts
* External Core: re-add code I removed mistakenly in last commitTim Chevalier2009-01-152-3/+16
|
* External Core lib: lots of cleanupTim Chevalier2009-01-148-166/+225
| | | | | | | | | - Factor out code for applying newtypes from Check into CoreUtils - Use this code in Prep, which allowed for some simplification - Change Merge and ElimDeadCode to not flatten top-level binds - Add a flag for elimDeadCode to tell it whether to keep exported bindings or not. - Other things.
* ext-core: change .cabal file so we can build with either GHC 6.8 or 6.10Tim Chevalier2009-01-052-12/+25
|
* ext-core: fix some Prep bugsTim Chevalier2009-01-051-60/+98
|
* ext-core: use shorter names when combining modulesTim Chevalier2009-01-052-4/+23
|
* ext-core: twiddle primitive thingsTim Chevalier2009-01-052-2/+8
|
* ext-core library: Parser fixes; make it build with the HEADTim Chevalier2008-09-185-12/+21
| | | | | | | | In the ext-core parser I guess I never tested: * existential type variable bindings in case alts * empty data declarations That'll learn me!
* ext-core library: Add dead code eliminator for CoreTim Chevalier2008-09-123-2/+128
| | | | Added code for dead code elimination to the ext-core library. This can be used in concert with Language.Core.Merge to produce a single self-contained module without unnecessary cruft.
* ext-core library: expose some more modulesTim Chevalier2008-09-121-2/+2
|
* ext-core library: Change syntax for primitive coercionsTim Chevalier2008-09-121-7/+6
| | | | Changed the ext-core syntax to include primitive coercions (left, right, sym, trans, etc.) as syntax rather than referring them to their names as in GHC. (I hope I updated the docs to reflect this...)
* ext-core library: Export a lot more things from PrimsTim Chevalier2008-09-122-17/+84
| | | | See comments for details.
* ext-core library: Extend Core preprocessorTim Chevalier2008-09-121-6/+70
| | | | See comments for details.
* ext-core library: Export a bunch more stuff from the parserTim Chevalier2008-09-121-1/+3
|
* ext-core library: Fix performance bugTim Chevalier2008-09-121-2/+11
| | | | isUtupleTy was implemented inefficiently (and is called a lot by the typechecker). Replaced with uglier but faster code.
* ext-core library: Remove some cruftTim Chevalier2008-09-121-4/+2
|
* ext-core library: Add code for merging multiple Core modules into a single ↵Tim Chevalier2008-09-124-3/+310
| | | | | | | | module I added a new module, Merge, to the ext-core library that combines a list of ext-core modules into a new, uniquely renamed module. See comments in Merge.hs for more details.
* Fixed performance bug in ext-core preprocessorTim Chevalier2008-08-094-41/+51
| | | | The Core preprocessor was rebuilding the type and data constructor environments every time it called the typechecker, which was horribly inefficient. Fixed.
* Fix some inconsistencies in the code and docs of primitivesIan Lynagh2008-06-232-25/+4
| | | | | | We were inconsistent about whether to use the name "MutArr#" or "MutableArray#". Likewise ByteArr#/ByteArray# and MutByteArr#/MutableByteArray#.
* More commandline flag improvementsIan Lynagh2008-06-161-1/+1
| | | | | | | * Allow -ffoo flags to be deprecated * Mark some -ffoo flags as deprecated * Avoid using deprecated flags in error messages, in the build system, etc * Add a flag to en/disable the deprecated flag warning
* Add dummy LICENSE file to make Cabal go throughTim Chevalier2008-05-171-0/+1
| | | | Add a LICENSE file that just points to the GHC license.
* don't rebuild PrimEnv if genprimopcode and/or primops.txt don't existTim Chevalier2008-05-151-3/+11
| | | | This helps if, for example, you want to build the Core tools on a machine that doesn't have a GHC build tree, and have a pre-existing copy of PrimEnv.hs.
* Cabalize ext-core toolsTim Chevalier2008-05-1421-125/+705
| | | | | | | | I cabalized the ext-core tools, so now they can be built as a library. The driver program has to be built separately. Also updated genprimopcode to reflect the new module hierarchy for the Core tools.
* External Core tools: add note to README about where to find documentationTim Chevalier2008-05-051-0/+6
|
* External Core tools: track new syntax for newtypesTim Chevalier2008-05-0511-284/+266
| | | | | | | Update External Core tools to reflect new syntax for newtypes. (Notice that the typechecker is 90 lines shorter!) Also: improve dependency-finding, miscellaneous refactoring.
* Improve syntax for primitive coercions in External CoreTim Chevalier2008-05-041-7/+6
| | | | | | Add new syntax in External Core for primitive coercions (trans, sym, etc.) rather than wiring their names into the ext-core parser.
* Fix External Core interpreterTim Chevalier2008-05-0314-395/+1032
| | | | | | | | | | | | The External Core interpreter works (in a limited sense). For details, see the README. This means we now have a marginally functioning set of External Core tools. The other exciting change is that the test driver (Driver.hs) now computes module dependencies automatically instead of having a wired-in list of library modules.
* Improve External Core syntax for newtypesTim Chevalier2008-04-224-44/+38
| | | | | I was confused by the newtype eta-contraction trick before. Newtype declarations are much less redundant now.
* External Core typechecker - improve handling of coercionsTim Chevalier2008-04-227-135/+183
| | | | | | | | Reorganized coercion-related code in the typechecker (this was brought about by typechecking the Core versions of the optimized GHC libraries.) A few miscellaneous changes (fixed a bug in Prep involving eta-expanding partial applications that had additional type arguments.)
* Improve External Core syntaxTim Chevalier2008-04-164-53/+84
| | | | | | | | | | Got rid of the silly '^' characters before qualified names (plus: reverts to the original syntax; minus: makes the parser a little hairier.) Also, added warning in the typechecker for coercion kind mismatches rather than considering that a type error. (see the added comment in Check.hs for details.)
* Revive External Core typecheckerTim Chevalier2008-04-1412-1061/+862
| | | | | | The typechecker works again! Yay! Details upon request.
* Revive External Core parserTim Chevalier2008-03-2911-135/+732
| | | | | | | | | | | | | | | | | | | | Huzzah, the External Core parser will now parse External Core generated by the HEAD. Most notably, I rewrote the parser in Parsec, but the old Happy version remains in the repository. I checked all the nofib benchmarks and most of the ghc-prim, base and integer libraries to make sure they parsed; one known bug: - Strings like "\x0aE", in which a hex escape code is followed by a letter that could be a hex digit, aren't handled properly. I'm investigating whether this is a bug in Parsec or expected behavior. The checker and interpreter still don't work, but should compile. Please mess around with the parser, report bugs, improve my code, etc., if you're so inclined.
* Handle hierarchical module names in External Core toolsTim Chevalier2008-03-209-17/+272
| | | | | | | | | | | | | | | I updated the parser to handle hierarchical module names (with package names) the way GHC is currently printing them out in External Core. Beware kludgy use of z-encoding and gratutious copy-pasta from GHC. You can now use the stand-alone Core parser to parse a very simple GHC-generated .hcr file (progress!) but not to typecheck or interpret it (the typechecker/interpreter don't snarf in the right libraries yet, among other things.) And, the parser is still incomplete in that it doesn't handle programs with newtypes/GADTs/etc. whose syntax has changed since 2003. In other words: probably don't try to use this yet.
* First cut at reviving the External Core toolsTim Chevalier2008-03-1012-180/+295
| | | | | | | | | | | | | | | | | | | | | | | | | I updated the External Core AST to be somewhat closer to reality (where reality is defined by the HEAD), and got all the code to compile under GHC 6.8.1. (That means it works, right?) Major changes: - Added a Makefile. - Core AST: - Represented package names and qualified module names. - Added type annotation on Case exps. - Changed Coerce to Cast. - Cleaned up representation of qualified/unqualified names. - Fixed up wired-in module names (no more "PrelGHC", etc.) - Updated parser/interpreter/typechecker/prep for the new AST. - Typechecker: - Used a Reader monad to pass around the global environment and top module name. - Added an entry point to check a single expression. - Prep: - Got rid of typeofExp; it's now defined in terms of the typechecker.
* Reorganisation of the source treeSimon Marlow2006-04-0712-0/+2695
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.