Couldnt send this with the form on 
http://haskell.systemsz.cs.yale.edu/hugs/bug-reports.html
for some reason.

Tried to create an ADT by not exporting the value
constructors from the module. If the constructor has
the same name as the type it is always available
even if not explicitly exported as 

   module Queue(Queue(Queue), ....) where

The defiition of q2 in UseQ should fail

   q2 = Queue [1,2,3]

And can be made to if the Queue module is changed to

    module Queue(Queue, ...) where

    data Queue a = Qu [a] 

and UseQ changed to

  module UseQ where
  import Queue

  q = enter 123 ( enter 345 ( enter 567 empty ))
  q2 = Qu [1,2,3]

Mark
-- 
Mark Skipper [EMAIL PROTECTED]     |  A fool's brain digests philosophy 
Dpt. Of Computer Science       |  into folly, science into superstition, 
De Montfort University.        |  and art into pedantry. 
The Gateway, Leicester LE1 9BH |  Hence University education.
http://www.cms.dmu.ac.uk/~mcs/ |                  -- George Bernard Shaw

useq.hs

queue.hs

Reply via email to