
Olaf Chitil
Above it looks like the wrong directory was created. Hat created the directory Hat/../Code when I think it should have created the directory ../Code/Hat.
I agree. The directory Hat should be put at the end of the import path, not at the begining.
The placement of the Hat directory (at the beginning or end of a path) is dependent on how the directory name is to be interpreted. A path corresponding to the hierarchical module namespace, like Code/Pictures/Jpg.hs should become Hat/Code/Pictures/Jpg.hs whereas a mere relative pathname with a flat namespace should be the opposite, e.g. ../Code/Pictures/Jpg.hs becomes ../Code/Pictures/Hat/Jpg.hs
This is a problem with hmake, not with the Hat tools themselves. Malcolm, could you modify hmake accordingly?
Actually, in this instance hmake guessed the directory correctly. The fault was with hat-trans, which simply assumed all paths were strictly hierarchical. The attached patch should fix it. Regards, Malcolm