On Oct 9, 2013, at 6:24 PM, Joachim Breitner wrote:
>
> So the conclusion is indeed: Let type class constraints have a nominal
> role, and all is fine.
But, then it would seem that any class with a superclass wouldn't be compatible
with GND. Do you see that detail as a consequence of this des
Hi,
not sure if this is not old news to you all, but I think that for this
discussion, it helps to consider these two aspects of a class instance
separately:
(1) An instance is a record of functions
(2) An instance is a function of sorts¹ from types to (1)
and clearly, type parameters of (1) c
On Oct 9, 2013, at 3:41 PM, Joachim Breitner wrote:
> what do you need the extra bit for? During GHD, can’t you just create
> the new dictionary (using "method = coerce original_method) and then see
> if it typechecks, i.e. if the method types can be coerced.
>
Efficiency. You're absolutely rig
The only class I'd want to preserve a representational roles for its
arguments for would be Coercible.
It does strike me as interesting to consider what it would mean to properly
check other instances for overlap when the instances are defined only 'up
to representation'.
It also strikes me as qu
On Wed, Oct 9, 2013 at 3:21 PM, Richard Eisenberg wrote:
> Now I think we're on the same page, and I *am* a little worried about the
> sky falling because of this. (That's not a euphemism -- I'm only a little
> worried.)
>
=)
> Wait! I have an idea!
> The way I've been describing GND all along
Hi,
Am Mittwoch, den 09.10.2013, 15:21 -0400 schrieb Richard Eisenberg:
> Wait! I have an idea!
> The way I've been describing GND all along has been an abbreviation.
> GHC does not coerce a dictionary from, say, Ord Int to Ord Age.
> Instead, GHC mints a fresh dictionary for Ord Age where all the
Now I think we're on the same page, and I *am* a little worried about the sky
falling because of this. (That's not a euphemism -- I'm only a little worried.)
Well, maybe I should be more worried.
The whole idea of roles is to protect against type-unsoundness. They are doing
a great job of that
NB: I'm told that building ghc with integer-simple doesn't work on linux?!
(though the person who told me this may not have filed a ticket about this
on trac, so i'm not sure if its still an issue with ghc head or not )
On Wed, Oct 9, 2013 at 2:47 PM, Carter Schonwald wrote:
> there seem to be
I'd be happy to be wrong. =)
We do seem to have stumbled into a design paradox though.
To make it so you can use roles in GeneralizedNewtypeDeriving hinges on the
parameter's role being representational, but making it representational
means users can also use coerce to turn dictionaries into othe
there seem to be two main approaches (which both require some testing)
1) build ghc with integer-simple
2) do some static linking tricks on your side, such as those described in
http://stackoverflow.com/questions/809794/use-both-static-and-dynamically-linked-libraries-in-gcc,
this might entail th
I remember Tim Dysinger telling me some incantations needed to statically
link Gmp into the static binary before deployment. I'll pester him to re
remember what's needed, but the point is there's a way.
On Wednesday, October 9, 2013, Yitzchak Gale wrote:
> > You may need to resort to
> > strace
I don't quite agree with your analysis, Edward.
Eq can be auto-derived, so it makes for a confusing example. Let's replace Eq
in your example with this class:
> class C a where
> c_meth :: a -> a -> Bool
Then, your example leads to the same embarrassing state of affairs: coercing a
dictionary
I just noticed there is a pretty big issue with the current default role
where typeclasses are concerned!
When implementing Data.Type.Coercion I had to use the fact that I could
apply coerce to the arguments of
data Coercion a b where
Coercion :: Coercible a b => Coercion a b
This makes sense
Hello,
My preference would be for the following design:
1. The default datatypes for roles are Nominal, but programmers can add
annotations to relax this.
2. Generlized newtype deriving works as follows: we can coerce a
dictionary for `C R` into `C T`, as long as we can coerce the types of all
m
If you really want to upload the package, then do
cabal upload dist/PrimitiveArray-0.5.2.0.tar.gz
(without -c).
I'd guess that the new hackage server doesn't yet support the API
required for -c. You can report this at
https://github.com/haskell/cabal/issues
although it will /probably/ end
Hi everybody,
Does anybody know what this means and how to resolve it? I have updated
my hackage account and can upload via the web interface, just not via
cabal. cabal config file is new as well.
cabal upload -c dist/PrimitiveArray-0.5.2.0.tar.gz
Checking dist/PrimitiveArray-0.5.2.0.tar.gz...
Er
I think it would be ok to expect the constructors to be visible, even
though it might need to a lot being needed.
BTW I think you might need S1 visible as well otherwise how would you
convert (S1 True :: S Bool Int) into (S1 True :: S Bool Age)?
If you don't derive the role from constructor visib
> You may need to resort to
> strace to find out what's trying to pull in libgmp.so.whatever.
I don't know how to do that. And anyway, I don't have access to
the machine on which the customer is reporting this. I do believe
the report - there is no compilation going on here, they are
only running
18 matches
Mail list logo