- 05 May, 2010 1 commit
-
-
Simon Marlow authored
-
- 02 Mar, 2010 4 commits
-
-
Ian Lynagh authored
-
Ian Lynagh authored
Now not only is if/then a bracketting pair, but then/else is too
-
Ian Lynagh authored
If enabled, these accept more layout, but give warnings
-
Ian Lynagh authored
It used to break on let {x = 'a'} in x as the 'in' token would keep closing contexts looking for an implicit 'let' layout.
-
- 10 Feb, 2010 1 commit
-
-
simonpj@microsoft.com authored
After some discussion we decided to make a quasi-quote look like [pads| ...blah... |] rather than [$pads| ...blah... |] as before. The new syntax is quieter, although it does not signal quite as clearly that there is a splice going on.
-
- 16 Jan, 2010 2 commits
-
-
Ian Lynagh authored
-
Ian Lynagh authored
It thought the ) needed to close something, but the $( hadn't opened anything.
-
- 17 Dec, 2009 1 commit
-
-
Simon Marlow authored
-
- 10 Dec, 2009 1 commit
-
-
Simon Marlow authored
The problem in #3741 was that we had confused column numbers with byte offsets, which fails in the case of UTF-8 (amongst other things). Fortunately we're tracking correct column offsets now, so we didn't have to make a calculation based on a byte offset. I got rid of two fields from the PState (last_line_len and last_offs).and one field from the AI (alex input) constructor.
-
- 05 Dec, 2009 1 commit
-
-
Ian Lynagh authored
-
- 03 Dec, 2009 2 commits
-
-
Ian Lynagh authored
-
Ian Lynagh authored
-
- 29 Nov, 2009 3 commits
-
-
Ian Lynagh authored
-
Ian Lynagh authored
-
Ian Lynagh authored
-
- 27 Nov, 2009 2 commits
-
-
Ian Lynagh authored
Also corrected a couple of line 0's to line 1
-
Ian Lynagh authored
-
- 18 Sep, 2009 1 commit
-
-
Simon Marlow authored
-
- 25 Nov, 2009 7 commits
-
-
Ian Lynagh authored
-
Ian Lynagh authored
And make the code simpler in the process!
-
Ian Lynagh authored
-
Ian Lynagh authored
-
Ian Lynagh authored
-
Ian Lynagh authored
-
Ian Lynagh authored
Caution: Largely untested
-
- 24 Nov, 2009 1 commit
-
-
Ian Lynagh authored
-
- 06 Nov, 2009 1 commit
-
-
Ben.Lippmeier@anu.edu.au authored
The type of the CmmLabel ctor is now CmmLabel :: PackageId -> FastString -> CmmLabelInfo -> CLabel - When you construct a CmmLabel you have to explicitly say what package it is in. Many of these will just use rtsPackageId, but I've left it this way to remind people not to pretend labels are in the RTS package when they're not. - When parsing a Cmm file, labels that are not defined in the current file are assumed to be in the RTS package. Labels imported like import label are assumed to be in a generic "foreign" package, which is different from the current one. Labels imported like import "package-name" label are marked as coming from the named package. This last one is needed for the integer-gmp library as we want to refer to labels that are not in the same compilation unit, but are in the same non-rts package. This should help remove the nasty #ifdef __PIC__ stuff from integer-gmp/cbits/gmp-wrappers.cmm
-
- 29 Oct, 2009 1 commit
-
-
simonpj@microsoft.com authored
-
- 28 Oct, 2009 1 commit
-
-
simonpj@microsoft.com authored
The change is this (see Trac #2798). Instead of writing mdo { a <- getChar ; b <- f c ; c <- g b ; putChar c ; return b } you would write do { a <- getChar ; rec { b <- f c ; c <- g b } ; putChar c ; return b } That is, * 'mdo' is eliminated * 'rec' is added, which groups a bunch of statements into a single recursive statement This 'rec' thing is already present for the arrow notation, so it makes the two more uniform. Moreover, 'rec' lets you say more precisely where the recursion is (if you want to), whereas 'mdo' just says "there's recursion here somewhere". Lastly, all this works with rebindable syntax (which mdo does not). Currently 'mdo' is enabled by -XRecursiveDo. So we now deprecate this flag, with another flag -XDoRec to enable the 'rec' keyword. Implementation notes: * Some changes in Lexer.x * All uses of RecStmt now use record syntax I'm still not really happy with the "rec_ids" and "later_ids" in the RecStmt constructor, but I don't dare change it without consulting Ross about the consequences for arrow syntax.
-
- 07 Oct, 2009 1 commit
-
-
simonpj@microsoft.com authored
This implements the Haskell Prime proposal http://hackage.haskell.org/trac/haskell-prime/wiki/ExplicitForall Flag is -XExplicitForAll Implied by Opt_RankNTypes, Opt_Rank2Types, Opt_ScopedTypeVariables, Opt_LiberalTypeSynonyms, Opt_ExistentialQuantification, Opt_PolymorphicComponents
-
- 10 Sep, 2009 1 commit
-
-
simonpj@microsoft.com authored
This patch implements three significant improvements to Template Haskell. Declaration-level splices with no "$" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This change simply allows you to omit the "$(...)" wrapper for declaration-level TH splices. An expression all by itself is not legal, so we now treat it as a TH splice. Thus you can now say data T = T1 | T2 deriveMyStuff ''T where deriveMyStuff :: Name -> Q [Dec] This makes a much nicer interface for clients of libraries that use TH: no scary $(deriveMyStuff ''T). Nested top-level splices ~~~~~~~~~~~~~~~~~~~~~~~~ Previously TH would reject this, saying that splices cannot be nested: f x = $(g $(h 'x)) But there is no reason for this not to work. First $(h 'x) is run, yielding code <blah> that is spliced instead of the $(h 'x). Then (g <blah>) is typechecked and run, yielding code that replaces the $(g ...) splice. So this simply lifts the restriction. Fix Trac #3467: non-top-level type splices ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ It appears that when I added the ability to splice types in TH programs, I failed to pay attention to non-top-level splices -- that is, splices inside quotatation brackets. This patch fixes the problem. I had to modify HsType, so there's a knock-on change to Haddock. Its seems that a lot of lines of code has changed, but almost all the new lines are comments! General tidying up ~~~~~~~~~~~~~~~~~~ As a result of thinking all this out I re-jigged the data type ThStage, which had far too many values before. And I wrote a nice state transition diagram to make it all precise; see Note [Template Haskell state diagram] in TcSplice Lots more refactoring in TcSplice, resulting in significantly less code. (A few more lines, but actually less code -- the rest is comments.) I think the result is significantly cleaner.
-
- 05 Sep, 2009 1 commit
-
-
simonpj@microsoft.com authored
-
- 27 Jul, 2009 1 commit
-
-
Simon Marlow authored
It still lives in darcs, if anyone wants to revive it sometime.
-
- 25 Jul, 2009 1 commit
-
-
Ian Lynagh authored
-
- 24 Jul, 2009 1 commit
-
-
Ian Lynagh authored
-
- 17 Jul, 2009 1 commit
-
-
Ian Lynagh authored
-
- 09 Jul, 2009 2 commits
-
-
Ian Lynagh authored
We already require GHC 6.8 to build, and that included stripPrefix in Data.List.
-
Ian Lynagh authored
This patch allow you to use "Language CPP", or even "LaNgUaGe CPP", if you wish, as the manual claims you can.
-
- 02 Jul, 2009 1 commit
-
-
simonpj@microsoft.com authored
-