
On Wed, Jun 17, 2015 at 12:14 AM, akash g
The phantom type doesn't appear on the actual constructors, only on the type signatures. In the function convertToReq, you are changing the following 1. The type. 2. The value of the price record (actually returning a new value with the price record changed to one and the rest of the fields being the same.
I'm not sure I see the difference between the given example and the "effectively phantom" type in foo :: Maybe String -> Maybe Int foo x@Nothing = x -- error: Nothing :: Maybe String is not compatible with Maybe Int foo x = ... -- brandon s allbery kf8nh sine nomine associates allbery.b@gmail.com ballbery@sinenomine.net unix, openafs, kerberos, infrastructure, xmonad http://sinenomine.net