home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / lang / function / 958 < prev    next >
Encoding:
Internet Message Format  |  1992-07-27  |  964 b 

  1. Path: sparky!uunet!mcsun!uknet!warwick!str-ccsun!strath-cs!st-and!ajtd
  2. From: ajtd@st-andrews.ac.uk (Antony J. T. Davie)
  3. Newsgroups: comp.lang.functional
  4. Subject: Re: programs that are too lazy
  5. Message-ID: <1992Jul27.083020.6061@st-andrews.ac.uk>
  6. Date: 27 Jul 92 08:30:20 GMT
  7. Organization: St. Andrews University, Scotland.
  8. Lines: 17
  9.  
  10. Julian Seward writes
  11. >I believe the Haskell committee should
  12. >consider the provision of two built-in functions:
  13. >
  14. >   hyperstrict, whnf :: Eq a => a -> b -> b
  15. >
  16. >both of which evaluate their first argument (fully or to whnf)
  17. >and return the second.  We can simulate this at the moment using
  18. >Haskell 1.2, but it might be more efficient if compilers could
  19. >regard these as primitive.
  20.  
  21. Whether or not one agrees with the provision of these fns., why restrict
  22. them to Eq types? Certainly one can only easily simulate them if they
  23. operate on equality types, but that's no reason to restrict primitive
  24. versions of them so.
  25.  
  26. Tony Davie
  27.