In GHC's Control.Arrow implementation, there are several rewrite rules
which exploit some properties of arrows. For example,
"compose/arr" forall f g . arr f >>> arr g = arr (f >>> g)
"first/arr" forall f . first (arr f) = arr (first f)
"second/arr" forall f . second (arr f) = arr (second f)
Hi SImon,
On Mar 29, 2007, at 5:40 AM, Simon Marlow wrote:
Hi Greg,
Good analysis so far. I think you're close to this one.
Thank you for checking over what I've done thus far.
Based on what you said, I looked at Compat.Unicode and there is
indeed a type error in this foreign call:
f
On Thu, Mar 29, 2007 at 10:40:32AM +0100, Simon Marlow wrote:
>
> Based on what you said, I looked at Compat.Unicode and there is indeed a
> type error in this foreign call:
>
> foreign import ccall unsafe "u_gencat"
> wgencat :: CInt -> Int
>
> The return type should be CInt, not Int. Try c
woops sorry for the previous post, the subject was wrong... this one is
correct.
Simon Peyton-Jones wrote:
Generally speaking GHC will inline *across* modules just as much as
it does *within* modules, with a single large exception.
If GHC sees that a function 'f' is called just once, it inl
Simon Peyton-Jones wrote:
Generally speaking GHC will inline *across* modules just as much as
it does *within* modules, with a single large exception.
If GHC sees that a function 'f' is called just once, it inlines it
regardless of how big 'f' is. But once 'f' is exported, GHC can
never se
On 29/03/2007, at 11:38, Mike Hamburg wrote:
Is there any way to use RULES substitutions with type classes?
I'm writing a reactive programming arrow (same idea as Yampa,
different
design goals), and it would help performance (and not just in the
speed
sense) to be able to tell when a value
haskell:
> Is there any way to use RULES substitutions with type classes?
>
> I'm writing a reactive programming arrow (same idea as Yampa, different
> design goals), and it would help performance (and not just in the speed
> sense) to be able to tell when a value derived with arr hasn't changed.
Hi Greg,
Good analysis so far. I think you're close to this one.
Based on what you said, I looked at Compat.Unicode and there is indeed a type
error in this foreign call:
foreign import ccall unsafe "u_gencat"
wgencat :: CInt -> Int
The return type should be CInt, not Int. Try changing t
Is there any way to use RULES substitutions with type classes?
I'm writing a reactive programming arrow (same idea as Yampa, different
design goals), and it would help performance (and not just in the speed
sense) to be able to tell when a value derived with arr hasn't changed.
So I'd like to be a
Right. There are two things going on in this thread. First, when you say
newtype T = MkT Int
then T and Int are distinct types. Adding a deriving( whatever ) doesn't
change that fact. Earlier messages make this point.
The second is that GHC's current "newtype deriving" mechanism is pl
10 matches
Mail list logo