I have three small questions.


1.
Haskell-98 description
- is it ready to print as the final, accepted and approved document?

2. 
Question by  Jose Emilio Labra Gayo <[EMAIL PROTECTED]>:

> Is it better to type the derived methods inside the class
> definition or out? Are there any efficiency penalties
> in any of the styles?
> [...]

Here is the concrete example (sorry, if i miss the point):

  class Num' a where  add,sub :: a -> a -> a
                      neg     :: a -> a
                      sub x y = add x (neg y)

What might be the cost overhead (depending on implementation!),
if we move  sub  to separate polymorphic function:

  sub :: Num' a => a -> a -> a
  sub x y = add x (neg y)

For, personally, i do not like many operations per class.


3. 
Module export:
if a module  N  has to export only a couple of instances for the 
constructor defined in  M,  how does it say that nothing else is for
export?
Thus, in the following example, one has to hide 
                                             localThing1, localThing2:
  module M ( C(..), ... )
  where
  data C a = ...
  -------------------
  module N ( ?? )
  where
  import M (C(..))
  instance ...=> I1 (C a) where  c x = localThing1 x
  instance ...=> I2 (C a) ...

  localThing1 = ...
  localThing2 = ...


Probably,  module N (C(..))  will do. Have we really to re-export C ?
  


Thank you in advance for the help.

------------------
Sergey Mechveliani
[EMAIL PROTECTED]







Reply via email to