
Hi, I'm just getting in to this hat thing and am experiencing a slight difficulty. My directory structure looks like .../projects .../projects/SemGraph .../projects/Util .../projects/NLP .../projects/FGL ... I'm in the SemGraph directory and am hmaking a program named AlignGraph. Inside Util there is a modeule Util.STM which is used in AlignGraph. I have ".." in my path when I hmake, and when I don't do hat, everything works fine. However, when I do use hat, hmake seems to look int the wrong place for the generated files: 9:16am moussor:SemGraph/ hmake -ghc AlignGraph.hs -I../FGL -I.. -package data -cpp -fvia-c -fglasgow-exts -hat hat-trans ../Util/STM.hs Wrote ../Util/TSTM.hs ghc -package data -cpp -fvia-c -fglasgow-exts -I../FGL -I.. -i../FGL -i.. -c -package hat -o ../TUtil/STM.o ../TUtil/STM.hs ghc-5.02.3: file `../TUtil/STM.hs' does not exist so it seems hat is creating ../Util/TSTM.hs, but hmake prepends the "T" to "Util" instead of "STM". This seems to be a hat problem; even though it creates Util/TSTM.hs, the name of the generated module is "TUtil.STM". Any suggestions on what to do about this? I can't imagine people haven't hit this wall before... - Hal -- Hal Daume III "Computer science is no more about computers | hdaume@isi.edu than astronomy is about telescopes." -Dijkstra | www.isi.edu/~hdaume

Hal Daume III
when I use hat, hmake seems to look in the wrong place for the generated files:
hat-trans ../Util/STM.hs Wrote ../Util/TSTM.hs ghc [...] ../TUtil/STM.hs ghc-5.02.3: file `../TUtil/STM.hs' does not exist
so it seems hat is creating ../Util/TSTM.hs, but hmake prepends the "T" to"Util" instead of "STM".
Yes, this is an hmake bug, specifically in how it handles the -hat flag in the presence of multiple source directories. I think it is not particularly related to the hierarchical namespace however.
This seems to be a hat problem; even though it creates Util/TSTM.hs, the name of the generated module is "TUtil.STM".
hat-trans does have a couple of small problems with hierarchical namespaces. As you notice, it has named the module wrongly. You will also find that some variables are named wrongly (syntactically incorrect) within the module.
Any suggestions on what to do about this? I can't imagine people haven't hit this wall before...
The standard caveat applies - Hat 2.00 is designed for pure Haskell'98, with almost no extensions. However, we do certainly plan to support hierarchical namespaces in the near future, because they are now supported by all Haskell implementations. Some ghc extensions are also likely to supported soon. Watch this space. Regards, Malcolm
participants (2)
-
Hal Daume III
-
Malcolm Wallace