[GHC] #8714: ExistentialQuantification plus DeriveDataTypeable leads to core lint error
GHC
ghc-devs at haskell.org
Wed Jan 29 18:14:57 UTC 2014
#8714: ExistentialQuantification plus DeriveDataTypeable leads to core lint error
----------------------------------+-------------------------------------
Reporter: CoreyOConnor | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 7.6.3
Keywords: | Operating System: Unknown/Multiple
Architecture: x86_64 (amd64) | Type of failure: None/Unknown
Difficulty: Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: |
----------------------------------+-------------------------------------
The attached program produces an core lint error when compiling with
optimization.
{{{
$ ghc -O -debug -dcore-lint Main
[1 of 1] Compiling Main ( Main.hs, Main.o )
*** Core Lint errors : in result of Float out(FOS {Lam = Just 0,
Consts = True,
PAPs = True}) ***
<no location info>: Warning:
In the type ‛cache_s16y’
@ cache_s16y is out of scope
*** Offending Program ***
Main.focusAst
:: forall syntax_aB4.
GHC.Types.Int
-> Main.BufferImpl syntax_aB4 -> Main.BufferImpl syntax_aB4
[LclIdX,
Arity=2,
Str=DmdType <L,U><S(S),1*U(U)>m,
Unf=Unf{Src=InlineStable, TopLvl=True, Arity=2, Value=True,
ConLike=True, WorkFree=True, Expandable=True,
Guidance=ALWAYS_IF(unsat_ok=True,boring_ok=False)
Tmpl= \ (@ syntax_aMw)
(r_aB5 [Occ=Once] :: GHC.Types.Int)
(b_aB6 [Occ=Once!] :: Main.BufferImpl syntax_aMw) ->
case b_aB6
of _ [Occ=Dead, Dmd=<L,A>]
{ Main.FBufferData ds_dOP [Occ=Once!, Dmd=<S,U>] ->
case ds_dOP
of _ [Occ=Dead, Dmd=<L,A>]
{ Main.HLState @ cache_s16y dt_s16z [Dmd=<C(C(S)),U>]
cache_s16A [Occ=Once, Dmd=<S,U>] ->
case dt_s16z r_aB5 cache_s16A of dt_XBQ { __DEFAULT ->
Main.FBufferData
@ syntax_aMw
(Main.HLState @ syntax_aMw @ cache_s16y dt_s16z dt_XBQ)
}
}
}}]
Main.focusAst =
\ (@ syntax_aMw)
(r_aB5 :: GHC.Types.Int)
(b_aB6 :: Main.BufferImpl syntax_aMw) ->
case b_aB6
of _ [Occ=Dead, Dmd=<L,A>] { Main.FBufferData ds_dOP [Dmd=<S,U>] ->
case ds_dOP
of _ [Occ=Dead] { Main.HLState @ cache_s220 dt_s221 cache_s222 ->
case dt_s221 r_aB5 cache_s222 of dt_XBQ { __DEFAULT ->
Main.FBufferData
@ syntax_aMw
(Main.HLState @ syntax_aMw @ cache_s220 dt_s221 dt_XBQ)
}
}
}
<snip>
}}}
The full log is attached.
The same error occurs with a GHC HEAD build from 2012/12/12. I will check
with a latest HEAD.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8714>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list