
6 Dec
2007
6 Dec
'07
10:03 p.m.
Is there some way to compile the following function in yhc? works in ghc with glasgow exts deactivated, yhc complains context for Prelude.read needed (in final line) readfloat :: String -> Maybe Float readfloat x | null parse || not (null leftover) = fail $ "myRead: "++x | otherwise = return v where parse@((v,leftover):ps) = readsPrec 0 x thanks! --- This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.