ghc.git
6 years agoFix build ghc-7.6.1-release
Ian Lynagh [Tue, 4 Sep 2012 13:09:19 +0000 (14:09 +0100)] 
Fix build

6 years agoUpdate version number and set RELEASE to YES
Ian Lynagh [Tue, 4 Sep 2012 13:01:14 +0000 (14:01 +0100)] 
Update version number and set RELEASE to YES

6 years agoMERGED: Fix fencepost and byte/word bugs in cloneArray/copyArray (#7185)
Ian Lynagh [Tue, 4 Sep 2012 13:00:12 +0000 (14:00 +0100)] 
MERGED: Fix fencepost and byte/word bugs in cloneArray/copyArray (#7185)

From:
    commit 8aabe8d06f7202c9a6cd1133e0b1ebc81338eed9
    Author: Simon Marlow <marlowsd@gmail.com>
    Date:   Tue Aug 28 15:52:38 2012 +0100

6 years agoRevert "Reduce the likelihood of x64/x86-64 changes breaking the build on other arche...
Ian Lynagh [Mon, 3 Sep 2012 18:03:00 +0000 (19:03 +0100)] 
Revert "Reduce the likelihood of x64/x86-64 changes breaking the build on other arches (#7083)."

This reverts commit a2e589a1dcd5c74447d8f12b2db79474cca73850.

Looks like it broke the build on x86/Windows.

6 years agoReduce the likelihood of x64/x86-64 changes breaking the build on other arches (...
Erik de Castro Lopo [Tue, 7 Aug 2012 20:44:00 +0000 (06:44 +1000)] 
Reduce the likelihood of x64/x86-64 changes breaking the build on other arches (#7083).

Code that needs to differentiate between i386 and x86-64 should now
be written as if x86-64 is the default and i386 is the special case.
Eg:

    # if i386_TARGET_ARCH
    someFuncion = .....
    # else
    someFuncion = .....
    # endif

MERGED from commit 2f7c578574a9d5e9b4d95847abc3d1cb1b35336d

6 years agosync-all: Add support for the 'remote set-branches' command
Ian Lynagh [Sun, 2 Sep 2012 14:51:10 +0000 (15:51 +0100)] 
sync-all: Add support for the 'remote set-branches' command

6 years agoUpdate ANNOUNCE for 7.6.1
Ian Lynagh [Sun, 2 Sep 2012 14:50:00 +0000 (15:50 +0100)] 
Update ANNOUNCE for 7.6.1

6 years agoAdd missing flag for respecting EXTRA_LIBDIR
Gabor Pali [Sun, 22 Jul 2012 16:59:56 +0000 (16:59 +0000)] 
Add missing flag for respecting EXTRA_LIBDIR

6 years agoFix Trac #7196 by adding a case to the desugarer
Simon Peyton Jones [Wed, 29 Aug 2012 09:57:48 +0000 (10:57 +0100)] 
Fix Trac #7196 by adding a case to the desugarer

Pls merge to 7.6

MERGED from commit f27c631a16a17b8ad740d7d28c6ff267fb189c2c

6 years agoEmit a warning for -rtsopts -shared, as well as -rtsopts -no-hs-main
Simon Marlow [Thu, 23 Aug 2012 08:49:12 +0000 (09:49 +0100)] 
Emit a warning for -rtsopts -shared, as well as -rtsopts -no-hs-main

-rtsopts has no effect with -shared, so we should emit a warning.  See
 #5373 and #7177.

MERGED from commit 9a3c8bd700a63dadcf1e238408b490908cbf6765

6 years agoFail earlier if there's an error in a type declaration
Simon Peyton Jones [Wed, 29 Aug 2012 10:33:33 +0000 (11:33 +0100)] 
Fail earlier if there's an error in a type declaration

This change means that we don't recover from erroneous type
declarations, thereby reporting fewer errors.  But trying to
recover confused GHC (leading to a pattern match failure in
the compiler Trac #7175), and it turned out to be tricky
to fix that.

So this patch takes the more conservative path of failing
earlier, perhaps reporting fewer real errors.

MERGED from commit d0ddde58f928a6b156d8061c406226c4fbb7cd22

6 years agoRefactor the way we infer types for functions in a mutually recursive group
Simon Peyton Jones [Tue, 21 Aug 2012 13:37:20 +0000 (14:37 +0100)] 
Refactor the way we infer types for functions in a mutually recursive group

See Note [Impedence matching] in TcBinds.
Fixes Trac #7173

MERGED from commit 1a591a0ce0e1b70eb5e6646542d5f110bfefc9af

6 years agoTwo small fixes to SpecConstr for functions with equality-proof args
Simon Peyton Jones [Thu, 23 Aug 2012 15:35:11 +0000 (16:35 +0100)] 
Two small fixes to SpecConstr for functions with equality-proof args

First, make Rules.match_co able to deal wit some modest coercions
Second, make SpecConstr use wild-card for coercion arguments

This is the rest of the fix for Trac #7165

MERGED from commit b04ff2fe83d8a5f9c176739559ac722521a7bdcc

6 years agoRe-jig the reporting of names bound multiple times
Simon Peyton Jones [Tue, 21 Aug 2012 13:35:12 +0000 (14:35 +0100)] 
Re-jig the reporting of names bound multiple times

Fixes Trac #7164

MERGED from commit 2c6d11fa17ff5cab7d62e6dbea3fc9e501fce7f3

6 years agoProfiling: open .prof when -hr<cc> is specified
Takano Akio [Wed, 15 Aug 2012 02:16:40 +0000 (11:16 +0900)] 
Profiling: open .prof when -hr<cc> is specified

The code for retainer profiling is used with e.g. +RTS -hc -hrfoo -RTS,
as well as with +RTS -hr -RTS.

MERGED from commit 4e0a957758af94bc39ff51814bad54faf96a94b9

6 years agoDon't specialise on implicit-parameter arguments in Specalise
Simon Peyton Jones [Thu, 23 Aug 2012 15:35:55 +0000 (16:35 +0100)] 
Don't specialise on implicit-parameter arguments in Specalise

This is a fix for Trac #7101

MERGED from commit 2f08f709cfdace23a4e32d80a57af349f7cc785a

6 years agoFix Trac #7092, involving Template Hsakell and name shadowing
Simon Peyton Jones [Tue, 28 Aug 2012 12:32:55 +0000 (13:32 +0100)] 
Fix Trac #7092, involving Template Hsakell and name shadowing

All the mechanism was there, but it wasn't being use for the
name-shadowing test.

MERGED from commit b2e8bed817483e80d721cc69720d3d547edab4f5

6 years agoDon't assume that coercion variables have (~) types
Simon Peyton Jones [Thu, 23 Aug 2012 10:04:22 +0000 (11:04 +0100)] 
Don't assume that coercion variables have (~) types

The constraint solver doesn't zonk the types of coercion variables
so we can't assume that a coercion variable will have a (~) type.

Fixes Trac #7090.

MERGED from commit d6918e9072e421178d59cd13ee352337a4090c39

6 years agoRetain ordering of finalizers during GC (#7160)
Simon Marlow [Mon, 20 Aug 2012 12:52:07 +0000 (13:52 +0100)] 
Retain ordering of finalizers during GC (#7160)

This came up since the addition of C finalizers, since Haskell
finalizers are already stored in an explicit list.  C finalizers on
the other hand get a WEAK object each, so in order to run them in the
right order we have to make sure that list stays in the correct
order.  I hate adding new invariants, but this is the quickest way to
fix the bug for now.  A better way to fix it would be to have a single
WEAK object with a list of finaliers attached to it, and a primop
for adding finalizers to the list.

MERGED from commit cec899d9fb668d4adccf731a63902e5be49f0660

6 years agoFix for optimizer bug on linux-powerpc (#6156).
Erik de Castro Lopo [Thu, 23 Aug 2012 10:39:47 +0000 (20:39 +1000)] 
Fix for optimizer bug on linux-powerpc (#6156).

MERGED from commit b4b78631890a4cd9cde1551de9a4440e7e750372

6 years agoFix missing case in coVarsOfTcCo
Simon Peyton Jones [Wed, 22 Aug 2012 15:13:56 +0000 (16:13 +0100)] 
Fix missing case in coVarsOfTcCo

Reported by Ganesh, Trac #7178.  Fix is easy.

MERGED from commit a0788a8b2ba19b7f3205010a71472342a75395f8

6 years agoFix :issafe command (#7172).
David Terei [Thu, 23 Aug 2012 08:59:05 +0000 (01:59 -0700)] 
Fix :issafe command (#7172).

MERGED from commit 93e8ae26e42fbe9e600db125182d7823a78e2925

6 years agoImprove Safe Haskell warn/error output.
David Terei [Thu, 23 Aug 2012 07:29:02 +0000 (00:29 -0700)] 
Improve Safe Haskell warn/error output.

MERGED from commit 2b5b178f4880b8034ef8c187e6227cfc09edf0d5

6 years agoMake badImportItem into a warning (#7167)
Paolo Capriotti [Thu, 23 Aug 2012 11:54:45 +0000 (12:54 +0100)] 
Make badImportItem into a warning (#7167)

Also fix a bug where a dodgy import warning was emitted for data
families with a single constructor.

MERGED from commit 3d7c81a4be00a6d72b321b4811ab316ea3301a60

6 years agoOS X: use mmap() instead of malloc for allocating the bss (#7040)
Simon Marlow [Mon, 20 Aug 2012 12:14:47 +0000 (13:14 +0100)] 
OS X: use mmap() instead of malloc for allocating the bss (#7040)

MERGED from commit e590ad77f9596a8389409ae56ea902c97e5dbfb0

6 years ago Numerous small changes to the constraint solver
Simon Peyton Jones [Wed, 22 Aug 2012 17:03:12 +0000 (18:03 +0100)] 
Numerous small changes to the constraint solver

    The main thing is that we now keep unsolved Derived constraints in the
    wc_flats of a WantedConstraints, rather than discarding them each time.
    This actually fixes a poential (admittedly obscure) bug, when we currently
    discard a superclass constraint, and may never re-generate it, and may
    thereby miss a functional dependency.

    Instead, reportErrors filters out Derived constraints that we don't want
    to report.

    The other changes are all small refactorings following our walk-through.

MERGED from commit 9c0a6bbb0194f65cd62e48936c0c00fc4888eef3 on HEAD

6 years agoAllocate a fresh META unique in newMetaKindVar
Simon Peyton Jones [Wed, 22 Aug 2012 17:01:57 +0000 (18:01 +0100)] 
Allocate a fresh META unique in newMetaKindVar

Fixes Trac #7176 on the branch.  HEAD has a better fix
(the big patch to untouchable handling)

6 years agoUse TcMType.growThetaTyVars (which works) rather than TcSimplify.growPreds (which...
Simon Peyton Jones [Wed, 15 Aug 2012 17:10:54 +0000 (18:10 +0100)] 
Use TcMType.growThetaTyVars (which works) rather than TcSimplify.growPreds (which doesn't)

I think this got left behind when we simplified and improved TcSimplify.  The effect
was that we had a function like
   class P a b | a -> b
   class Q b c | b -> c

   f :: (P a b, Q b c) => a -> a

and were were failing to quanitfy over 'c', even though it is (indirectly) determined
by 'a'.

This make Programatica fail to compile: Trac #7147

MERGED from commit de07bf2657fc5709331ad933b5563fac97b1a05b

6 years agoAllow a vew pattern or bang pattern in a record pattern.
Takano Akio [Thu, 16 Aug 2012 10:13:47 +0000 (11:13 +0100)] 
Allow a vew pattern or bang pattern in a record pattern.

e.g.
        data T = MkT { x,y :: Int }

        f (MkT { x = !v, y = negate -> w }) = v + w

MERGED from commit 41c7342e7937dab55d082a0c5612f783e7eaa855

6 years agoFix environment update for type instance declarations in GHCi (#7117)
Paolo Capriotti [Mon, 13 Aug 2012 17:26:34 +0000 (18:26 +0100)] 
Fix environment update for type instance declarations in GHCi (#7117)

Patch by Patrick Palka <patrick@parcs.ath.cx>

MERGED from commit 700d287fb11dadfd1e91875e2008c4002cd883a3

6 years agoRequire DataKinds for promoted list/tuple syntax in types
Simon Peyton Jones [Wed, 15 Aug 2012 15:01:19 +0000 (16:01 +0100)] 
Require DataKinds for promoted list/tuple syntax in types

Fixes Trac #7151

MERGED from commit 72e7f57cb4326c797f63d0c0c976241c02328209

6 years agoFix Trac #7145, by recording uses of constructor "children" in export lists
Simon Peyton Jones [Wed, 15 Aug 2012 13:24:26 +0000 (14:24 +0100)] 
Fix Trac #7145, by recording uses of constructor "children" in export lists

MERGED from commit 10377bba65de7463b909cc7cd5781a46620f305a

6 years agoTest FlexibleInstance not UndecidableInstances in the ambiguity check
Simon Peyton Jones [Wed, 15 Aug 2012 15:02:03 +0000 (16:02 +0100)] 
Test FlexibleInstance not UndecidableInstances in the ambiguity check

Fixes Trac #7131

MERGED from commit f7b096e8630c91a17ff9a551ab15060b21d84eb0

6 years agoFix Trac #7128, by zonking kind varaibles more assiduously when typechecking a class...
Simon Peyton Jones [Tue, 14 Aug 2012 16:06:00 +0000 (17:06 +0100)] 
Fix Trac #7128, by zonking kind varaibles more assiduously when typechecking a class declaration

MERGED from commit e949162653b65d8e48573e84583c6509be2f24ed

6 years agoTH: Pragmas refactoring.
Mikhail Vorozhtsov [Tue, 10 Jul 2012 14:37:42 +0000 (21:37 +0700)] 
TH: Pragmas refactoring.

Also adds RULES and 'SPECIALIZE instance' support.

MERGED from commit 1993ee4ba8d30d6774c2330477a1eecf865dfa1f

6 years agoapplying simonpj's fix from #7022 (with 80-col reformatting)
Simon Marlow [Thu, 2 Aug 2012 10:47:51 +0000 (11:47 +0100)] 
applying simonpj's fix from #7022 (with 80-col reformatting)

MERGED from commit 15e4f93b661fe83cff96c8c295e7ea8985aa08a

6 years agoPut kind variables before type variables when quantifying
Simon Peyton Jones [Wed, 15 Aug 2012 14:59:26 +0000 (15:59 +0100)] 
Put kind variables before type variables when quantifying

This is a pretty egregious error; I'm surprised it has lasted so long!

Fixes Trac #7124

MERGED from commit bdce8f0a3b40a60108a99b4635d168c12b79f255

6 years agoAdd reference to defer-type-errors in the release notes.
Paolo Capriotti [Wed, 15 Aug 2012 16:08:39 +0000 (17:08 +0100)] 
Add reference to defer-type-errors in the release notes.

6 years agoDocument -fdefer-type-errors
Simon Peyton Jones [Tue, 14 Aug 2012 16:31:18 +0000 (17:31 +0100)] 
Document -fdefer-type-errors

Thanks to Paolo for most of the work.

MERGED from commit 3fabf48e0c5be2d7c2f6ea028115fdb9b4045d97

6 years agoMake .t files when running haddock
Ian Lynagh [Tue, 14 Aug 2012 17:24:01 +0000 (18:24 +0100)] 
Make .t files when running haddock

These files contain the "+RTS -t --machin-readable" output, so that
we can spot performance regressions.

6 years agoMore dependency updates.
Paolo Capriotti [Tue, 14 Aug 2012 12:50:40 +0000 (13:50 +0100)] 
More dependency updates.

6 years agoUpdate dependencies.
Paolo Capriotti [Tue, 14 Aug 2012 11:59:21 +0000 (12:59 +0100)] 
Update dependencies.

6 years agoFix GHCi segfault during startup on linux-powerpc (#2972).
Erik de Castro Lopo [Mon, 30 Jul 2012 19:53:49 +0000 (05:53 +1000)] 
Fix GHCi segfault during startup on linux-powerpc (#2972).

Slightly modified version of a patch from Ben Collins <bcollins@ubuntu.com>
who did the final debugging that showed the segfault was being caused the
memory protection mechanism.

Due to the requirement of "jump islands" to handle 24 bit relative jump
offsets, GHCi on PowerPC did not use mmap to load object files like the
other architectures. Instead, it allocated memory using malloc and fread
to load the object code. However there is a quirk in the GNU libc malloc
implementation. For memory regions over certain size (dynamic and
configurable), malloc will use mmap to obtain the required memory instead
of sbrk and malloc's call to mmap sets the memory readable and writable,
but not executable. That means when GHCi loads code into a memory region
that was mmapped instead of malloc-ed and tries to execute it we get a
segfault.

This solution drops the malloc/fread object loading in favour of using
mmap and then puts the jump island for each object code module at the
end of the mmaped region for that object.

This patch may also be a solution on other ELF based powerpc systems
but does not work on darwin-powerpc.

MERGED from commit 3e6c9308777caf83122baef504028d619d3dd588

6 years agoAdd UnboxedTuples changes to release notes.
Paolo Capriotti [Mon, 13 Aug 2012 12:13:06 +0000 (13:13 +0100)] 
Add UnboxedTuples changes to release notes.

6 years agoFix ambiguous flag resolution (#7138)
Paolo Capriotti [Mon, 13 Aug 2012 11:48:29 +0000 (12:48 +0100)] 
Fix ambiguous flag resolution (#7138)

Pick longest flag when more than one matches in findArg.

This fixes an issue where -ignore-dot-ghci wasn't honored, because the
flag was parsed as "-i gnore-dot-ghci".

MERGED from commit f78b31a36b5b49afbdea199269319faca261c898

6 years agoUpdate 'unboxed tuples' section of users guide.
Austin Seipp [Sun, 5 Aug 2012 20:06:33 +0000 (15:06 -0500)] 
Update 'unboxed tuples' section of users guide.

In particular, many of the restrictions on using unboxed tuples went
away thanks to Max Bolingbroke, and they can now be bound to variables
without pattern matching, and passed as arguments.

Also fix a little formatting in glasgow-exts.xml. Some other parts
of this section may be out of date.

Signed-off-by: Austin Seipp <mad.one@gmail.com>
MERGED from commit 7473c3d291742175e2e2a4ba98f0c1dba5393599

6 years agoDon't pass -Wimplicit to the C++ compiler.
Austin Seipp [Sun, 5 Aug 2012 08:26:45 +0000 (03:26 -0500)] 
Don't pass -Wimplicit to the C++ compiler.

Supresses an ugly warning from gcc 4.6+ saying this is a C/ObjC flag
only.

Signed-off-by: Austin Seipp <mad.one@gmail.com>
MERGED from commit a0e308de485bdb275008a40de9c76c31230e6c51

6 years agoUpdate release notes for GHC and base.
Paolo Capriotti [Sun, 12 Aug 2012 10:45:14 +0000 (11:45 +0100)] 
Update release notes for GHC and base.

6 years agoFix a bug in the handling of recent_activity
Simon Marlow [Tue, 7 Aug 2012 13:44:46 +0000 (14:44 +0100)] 
Fix a bug in the handling of recent_activity

The problem occurred when the idle GC was turned off with +RTS -I0.
Then the scheduler would go into the state ACTIVITY_DONE_GC directly
without doing a GC, and a subsequent GC would put it back to
ACTIVITY_YES but without turning the timer back on.  Instead if the GC
finds the state is ACTIVITY_DONE_GC it should leave it there.

MERGED from commit 396f09031b363bf2f0d2afa28a86e67a0628a696

6 years agoAdd cast to placate gcc 4.6 on linux-powerpc (#7113).
Erik de Castro Lopo [Fri, 3 Aug 2012 05:14:35 +0000 (15:14 +1000)] 
Add cast to placate gcc 4.6 on linux-powerpc (#7113).

MERGED from commit 50f5016a67060538a5272cd5fa6f4532d0396ef2

6 years agoDo calcUnfoldingGuidance on the *non* occ-analysed RHS
Simon Peyton Jones [Fri, 20 Jul 2012 19:07:51 +0000 (20:07 +0100)] 
Do calcUnfoldingGuidance on the *non* occ-analysed RHS

See Note [Calculate unfolding guidance on the non-occ-anal'd expression]
This makes a big difference to residency (530M vs over 800M when compiling
Cabal).

This fixes the majority of the regression in Trac #6104

MERGED from commit cd627bcfda713efa63b7f5290c84a5077f4976f9

6 years agoFix build on Windows: Configure packages in the right order
Ian Lynagh [Tue, 24 Jul 2012 14:11:18 +0000 (15:11 +0100)] 
Fix build on Windows: Configure packages in the right order

Also added a comment explaining that addPackages need to be in
dependency order.

6 years agoFix references to repositories in the user guide
Paolo Capriotti [Fri, 3 Aug 2012 12:39:52 +0000 (13:39 +0100)] 
Fix references to repositories in the user guide

7 years agoThe dph libraries are not required in the 7.6 branch
Ian Lynagh [Tue, 20 Dec 2011 17:33:41 +0000 (17:33 +0000)] 
The dph libraries are not required in the 7.6 branch

And we don't build them by default, as they shouldn't go into the
release.

7 years agoBump version to 7.6.0
Paolo Capriotti [Tue, 10 Jul 2012 09:39:44 +0000 (10:39 +0100)] 
Bump version to 7.6.0

7 years agoUpdate dependencies.
Paolo Capriotti [Tue, 10 Jul 2012 16:58:41 +0000 (17:58 +0100)] 
Update dependencies.

7 years agoUpdate to time 1.4.0.1
Paolo Capriotti [Tue, 10 Jul 2012 15:42:34 +0000 (16:42 +0100)] 
Update to time 1.4.0.1

7 years agoMerge branch 'master' of http://darcs.haskell.org/ghc
Dimitrios Vytiniotis [Thu, 19 Jul 2012 12:35:24 +0000 (14:35 +0200)] 
Merge branch 'master' of darcs.haskell.org/ghc

7 years agoCleaning up the extractUnsolved story.
Dimitrios Vytiniotis [Thu, 19 Jul 2012 12:32:15 +0000 (14:32 +0200)] 
Cleaning up the extractUnsolved story.

7 years agoKeeping Derived constraints in the unsolved
Dimitrios Vytiniotis [Thu, 19 Jul 2012 09:28:40 +0000 (11:28 +0200)] 
Keeping Derived constraints in the unsolved
parts of WantedConstraints, and other small refactorings.

7 years agoPreserve synonyms if possible (leads to better error messages) through flattening.
Dimitrios Vytiniotis [Thu, 19 Jul 2012 09:26:45 +0000 (11:26 +0200)] 
Preserve synonyms if possible (leads to better error messages) through flattening.

7 years agoSmall refactoring in the generation of superclasses.
Dimitrios Vytiniotis [Wed, 18 Jul 2012 14:49:06 +0000 (16:49 +0200)] 
Small refactoring in the generation of superclasses.

7 years agoFirst batch of file additions for cross-compiler:
Gabor Greif [Wed, 18 Jul 2012 13:03:31 +0000 (15:03 +0200)] 
First batch of file additions for cross-compiler:

new file:   ghc/ghc-cross.wrapper
new file:   includes/mkDerivedConstants.cross.awk
new file:   includes/mkSizeMacros.cross.awk
new file:   rules/cross-compiling.mk

These are expected to sit quietly in the tree until
the rest of the machinery matures on an (upcoming)
branch. Reviews will begin to make sense as soon as
that has happened. Anyway, comments are welcome. See
<http://www.haskell.org/pipermail/cvs-ghc/2012-July/074456.html>
for background.

Disclaimer: these source files are not (yet) up to the
            quality standards set by the rest of the tree.

Cleanups, move-arounds and rewrites (i.e. .awk -> .hs), as
well as additional comments and documentation will happen
as soon as the basic functionality of a cross-compiler is
working reliably.

7 years agocomment-only typo
Gabor Greif [Wed, 18 Jul 2012 12:15:05 +0000 (14:15 +0200)] 
comment-only typo

7 years agouse idiomatic type
Gabor Greif [Sun, 8 Jan 2012 14:51:39 +0000 (15:51 +0100)] 
use idiomatic type

7 years agoghc-pkg: restore -no-user-package-conf flag.
Paolo Capriotti [Wed, 18 Jul 2012 09:39:08 +0000 (10:39 +0100)] 
ghc-pkg: restore -no-user-package-conf flag.

7 years agoReorder libraries to account for unix dependency on time.
Paolo Capriotti [Tue, 17 Jul 2012 17:44:25 +0000 (18:44 +0100)] 
Reorder libraries to account for unix dependency on time.

7 years agoRemove hPrintDump and make rule dump output more consistent (#7060)
Paolo Capriotti [Tue, 17 Jul 2012 15:24:26 +0000 (16:24 +0100)] 
Remove hPrintDump and make rule dump output more consistent (#7060)

The only difference between SevDump and SevOutput in defaultLogAction is
an extra blank line, so we don't need a separate hPrintDump function.

Also make -ddump-to-file consistent with the stdout version, by avoiding
to add the extra empty line when dumping rules.

7 years agoRestore old output for -ddump-rule-firings #7060
Paolo Capriotti [Tue, 17 Jul 2012 15:11:02 +0000 (16:11 +0100)] 
Restore old output for -ddump-rule-firings #7060

Commit 3fcf5bdff7a22e22d7265535369cd8f867141ec1 made the output of
-ddump-rule-firings and -ddump-rule-rewrites excessively verbose.

Fixed by removing the extra blank lines and separator when the header
of dump is empty.

7 years agotypos in trace strings (which I observed in compile output)
Gabor Greif [Wed, 18 Jul 2012 10:25:58 +0000 (12:25 +0200)] 
typos in trace strings (which I observed in compile output)

7 years agomade comments C-style, so that no gcc-extension is needed
Gabor Greif [Wed, 18 Jul 2012 10:14:16 +0000 (12:14 +0200)] 
made comments C-style, so that no gcc-extension is needed

also removed an unnecessary 'struct' tag (since the struct is
not recursive); this is in line with the other struct definitions

fixed a typo, updated copyright

it remains to remove the tabs and align the structure members
accordingly

7 years agotypos in comments
Gabor Greif [Wed, 18 Jul 2012 08:33:46 +0000 (10:33 +0200)] 
typos in comments

this is also my test commit and
reduces the lines in the cross-
compiler branch

7 years agoMerge branch 'master' of darcs.haskell.org:/home/darcs/ghc
Simon Peyton Jones [Tue, 17 Jul 2012 15:40:51 +0000 (16:40 +0100)] 
Merge branch 'master' of darcs.haskell.org:/home/darcs/ghc

7 years agofix warnings
Simon Marlow [Tue, 17 Jul 2012 08:43:06 +0000 (09:43 +0100)] 
fix warnings

7 years agoRefactor and simplify the SRT handling
Simon Marlow [Tue, 17 Jul 2012 08:25:16 +0000 (09:25 +0100)] 
Refactor and simplify the SRT handling

7 years agotidy up pretty-printing of CmmCall
Simon Marlow [Thu, 12 Jul 2012 10:14:57 +0000 (11:14 +0100)] 
tidy up pretty-printing of CmmCall

7 years agoMove sinking into a separate module, and add a simple inlining pass
Simon Marlow [Thu, 12 Jul 2012 09:58:00 +0000 (10:58 +0100)] 
Move sinking into a separate module, and add a simple inlining pass

7 years agoAdd a comment about how SRTs work
Simon Marlow [Thu, 12 Jul 2012 08:12:45 +0000 (09:12 +0100)] 
Add a comment about how SRTs work

7 years agono need to export cafTransfers
Simon Marlow [Thu, 12 Jul 2012 08:12:30 +0000 (09:12 +0100)] 
no need to export cafTransfers

7 years agoConvert (co1 -> co2) to an IfaceFunTy, rather than IfaceTcApp
Simon Peyton Jones [Mon, 16 Jul 2012 16:03:40 +0000 (17:03 +0100)] 
Convert (co1 -> co2) to an IfaceFunTy, rather than IfaceTcApp

This is more compact, and pretty-prints more nicely too.

7 years agoImprove pretty printing for 'rec' Stmts, using pprDeeper
Simon Peyton Jones [Mon, 16 Jul 2012 16:02:07 +0000 (17:02 +0100)] 
Improve pretty printing for 'rec' Stmts, using pprDeeper

Fixes Trac #7074

7 years agoMerge branch 'master' of darcs.haskell.org:/home/darcs/ghc
Simon Peyton Jones [Mon, 16 Jul 2012 15:18:33 +0000 (16:18 +0100)] 
Merge branch 'master' of darcs.haskell.org:/home/darcs/ghc

7 years agoReover from validity errors in type/class decls
Simon Peyton Jones [Mon, 16 Jul 2012 15:18:17 +0000 (16:18 +0100)] 
Reover from validity errors in type/class decls

This lets us report slightly more errors in one sweep

7 years agoremove tabs
Simon Marlow [Mon, 16 Jul 2012 11:10:12 +0000 (12:10 +0100)] 
remove tabs

7 years agoRemove tabs
Simon Marlow [Mon, 16 Jul 2012 10:23:50 +0000 (11:23 +0100)] 
Remove tabs

7 years agoWrite locale character encoding to hpc html report (#5006)
Bas van Dijk [Mon, 16 Jul 2012 10:20:23 +0000 (11:20 +0100)] 
Write locale character encoding to hpc html report (#5006)

This allows the correct interpretation of Unicode characters by the browser.

7 years agoImplemented MultiWayIf extension.
Mikhail Vorozhtsov [Sat, 14 Jul 2012 17:53:52 +0000 (00:53 +0700)] 
Implemented MultiWayIf extension.

7 years agoImplemented \case expressions.
Mikhail Vorozhtsov [Sat, 23 Apr 2011 05:06:38 +0000 (12:06 +0700)] 
Implemented \case expressions.

7 years agoDo not discard insoluble constraints in simplifyInfer
Simon Peyton Jones [Sat, 14 Jul 2012 12:18:34 +0000 (13:18 +0100)] 
Do not discard insoluble constraints in simplifyInfer

Before -fdefer-type-errors there we no insolubles
(because we'd have failed before then), but with -fdefer-type-errors
there can be.  The code is acutally a bit simpler: we just call
emitConstraints, and eliminate the bogus-looking emitWC from TcRnMonad.

There's a bit more tidying up to do, concerning the places we use
keepWanted, but I need to talk to Dimitrios about that.

Meanwhile this fixes Trac #7023

7 years agoComments only
Simon Peyton Jones [Sat, 14 Jul 2012 12:13:45 +0000 (13:13 +0100)] 
Comments only

7 years agoComments only
Simon Peyton Jones [Sat, 14 Jul 2012 12:13:24 +0000 (13:13 +0100)] 
Comments only

7 years agoComments about associated type tyvar naming
Simon Peyton Jones [Sat, 14 Jul 2012 12:12:59 +0000 (13:12 +0100)] 
Comments about associated type tyvar naming

7 years agoWhen checking associated type instances, check that
Simon Peyton Jones [Sat, 14 Jul 2012 12:12:13 +0000 (13:12 +0100)] 
When checking associated type instances, check that
the *type* indices match those of the class instance.
We don't need to track tke kind indices, and indeed
thay don't have the same careful name scoping.
See the notes in checkValidClass.

Fixes Trac #7073

7 years agoSmall tidy-up
Ian Lynagh [Fri, 13 Jul 2012 17:28:14 +0000 (18:28 +0100)] 
Small tidy-up

7 years agoDon't use tracingDynFlags in assertPprPanic
Ian Lynagh [Fri, 13 Jul 2012 17:15:57 +0000 (18:15 +0100)] 
Don't use tracingDynFlags in assertPprPanic

It wasn't needed, but was left over as an oversight

7 years agoFix build with GHC 7.0
Ian Lynagh [Fri, 13 Jul 2012 17:14:01 +0000 (18:14 +0100)] 
Fix build with GHC 7.0

7 years agoMerge branch 'master' of darcs.haskell.org:/home/darcs/ghc
Simon Peyton Jones [Fri, 13 Jul 2012 13:26:36 +0000 (14:26 +0100)] 
Merge branch 'master' of darcs.haskell.org:/home/darcs/ghc

7 years agoDocument bug in the x86 NCG w.r.t. -fexcess-precision (#7069)
Simon Marlow [Fri, 13 Jul 2012 09:23:12 +0000 (10:23 +0100)] 
Document bug in the x86 NCG w.r.t. -fexcess-precision (#7069)

7 years agoUse dumpSDoc functions to output rules (#7060)
Paolo Capriotti [Thu, 12 Jul 2012 16:53:50 +0000 (17:53 +0100)] 
Use dumpSDoc functions to output rules (#7060)

Make -ddump-rules, -ddump-rule-firings and -ddump-rule-rewrites
behave like the other -ddump flags, by using the dumpSDoc function
instance of pprDefiniteTrace.

7 years agoAdd MonadIO instance to SimplM.
Paolo Capriotti [Thu, 12 Jul 2012 16:49:41 +0000 (17:49 +0100)] 
Add MonadIO instance to SimplM.