[darcs-users] [PATCH, RESEND] Eliminate HopefullyPrivate (rename over Hopefully)

Simon Michael simon at joyful.com
Sat Aug 9 16:41:33 UTC 2008


Second thoughts!

I had trouble understanding and applying this patch. It complained about 
removing an non-empty file, but then did it anyway. I obliterated the 
patch and then noticed my my repo was inconsistent, with Hopefully.lhs 
containing 0 bytes. darcs check confirmed, darcs repair fixed it. That's 
a bad patch.

About what it does: note the haskell_policy.sh test disallows any import 
of HopefullyPrivate. David's " don't use HopefullyPrivate outside of 
Hopefully." patch[1] said:

"The idea is to hide the Hopefully constructors, so I can hide some more
information in there, if I like, which should be handy for the hashed
inventories, and may also come in handy (for similar reasons) with git
repositories."

I don't fully understand, but it looks like YAGNI[2] right now and it 
seems to me we should do this: move HopefullyPrivate.lhs's contents into 
Hopefully.lhs, check it exports only what it should, remove that test 
from haskell_policy.sh.



[1] 
http://joyful.com/darcsweb/darcsweb.cgi?r=darcs;a=commitdiff;h=20061210231623-72aca-1969d16576b0cb6358a9f2b4ce268763ce3f6b72.gz

[2] http://en.wikipedia.org/wiki/You_Ain%27t_Gonna_Need_It



More information about the darcs-users mailing list