> > Here's another: ...
> >     Make getInt (and friends) behave differently depending on the mode
> >     of the cursor they're passed: either allocate a buffer and return
> >     _|_, decode and return the current column of the current row, or
> >     free a buffer and return _|_.
> 
> Not wanting to sound too dumb, but how do you return _|_ ?

Return

  undefined

or better,

  error "Erroneously demanded bottom result of buffer allocation phase"

Note that

  undefined :: a
  undefined = undefined

  error :: String -> a
  {- defined internally -}

HTH.

--KW 8-)
  
-- 
Keith Wansbrough <[EMAIL PROTECTED]>
http://www.cl.cam.ac.uk/users/kw217/
University of Cambridge Computer Laboratory.

_______________________________________________
Haskell-Cafe mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to