
Ok, I thought I'd try out the latest CVS Hugs with the new libraries, so I can try to avoid checking in breaking changes to the libraries in the future. Here's where I got to: - I discovered that saying 'make' in src/unix gives you a version of Hugs that works well in-place without having to give it any extra options. This is nice, perhaps the Install doc could mention it? - 'make libraries' in src/ seemed to go smoothly. Then I discovered that I couldn't :load Foreign in Hugs, because it needs the FFI declarations to be processed first (the docs do mention this, but I don't read docs until something goes wrong :-) - So I tried 'make install_libraries_ffi' which looks like it ought to do the right thing. I commented out the dependencies on 'install' etc. since I don't want to install anything (perhaps this could be an option? or a separate make target?). Anway, I got the following error: ~/tmp/hugs98/src > make install_libraries_ffi ./ffihugs -P'{Hugs}/libraries:{Hugs}/oldlib:{Hugs}/lib/hugs' +G +L"../libraries/Hugs/Storable_aux.c" Hugs.Storable runhugs: Error occurred Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/Prelude.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Prelude.hs": Reading file "/home/simonmar/tmp/hugs98/lib/hugs/HugsDynamic.hs": Reading file "/home/simonmar/tmp/hugs98/oldlib/IOExts.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/IOExts.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/IO.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/Ix.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/IO.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/IOExts.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/IORef.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/IOArray.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/Array.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/List.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/Maybe.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/List.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/Array.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/Dynamic.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/Either.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/Int.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/Int.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/Bits.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/Int.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/Int.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/Word.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/Word.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/Ratio.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/Word.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/Word.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Foreign/Ptr.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Foreign/StablePtr.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/StablePtr.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Foreign/StablePtr.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Data/Dynamic.hs": Reading file "/home/simonmar/tmp/hugs98/libraries/Hugs/IOArray.hs": Reading file "/home/simonmar/tmp/hugs98/oldlib/IOExts.hs": Reading file "/home/simonmar/tmp/hugs98/oldlib/Addr.hs": Reading file "/home/simonmar/tmp/hugs98/lib/hugs/HugsDynamic.hs": INTERNAL ERROR: checkImportEntity2 Cheers, Simon

On Wed, Sep 11, 2002 at 12:42:21PM +0100, Simon Marlow wrote:
- So I tried 'make install_libraries_ffi' which looks like it ought to do the right thing. I commented out the dependencies on 'install' etc. since I don't want to install anything (perhaps this could be an option? or a separate make target?).
It's a bit of a glitch with the Hugs ffi setup that it only works on an install. Something about hardwired filenames.
./ffihugs -P'{Hugs}/libraries:{Hugs}/oldlib:{Hugs}/lib/hugs' +G +L"../libraries/Hugs/Storable_aux.c" Hugs.Storable runhugs: Error occurred [...] Reading file "/home/simonmar/tmp/hugs98/lib/hugs/HugsDynamic.hs": INTERNAL ERROR: checkImportEntity2
This happened in Sigbjorn's commit to static.c last night -- it blows up on import IOExts(unsafePerformIO) (or anything else from IOExts) and affects both old and new library setups. If you roll static.c back to 1.88, this should work (though that reinstates an obscure bug in the module system).

"Ross Paterson"
On Wed, Sep 11, 2002 at 12:42:21PM +0100, Simon Marlow wrote: ...
runhugs: Error occurred [...] Reading file "/home/simonmar/tmp/hugs98/lib/hugs/HugsDynamic.hs": INTERNAL ERROR: checkImportEntity2
This happened in Sigbjorn's commit to static.c last night -- it blows up on import IOExts(unsafePerformIO) (or anything else from IOExts) and affects both old and new library setups. If you roll static.c back to 1.88, this should work (though that reinstates an obscure bug in the module system).
Sorry about that, the intro'ed problem has now been cleared up, I believe. --sigbjorn

On Wed, Sep 11, 2002 at 07:51:40AM -0700, Sigbjorn Finne wrote:
Sorry about that, the intro'ed problem has now been cleared up, I believe.
But now module exports are broken: module A(f) where f = id module B(module A) where import A module C where import B(f) ERROR "C.hs" - Unknown entity "f" imported from module "B"

Thanks, now up tidied. Surprised this one wasn't
caught by the regression tests.
--sigbjorn
----- Original Message -----
From: "Ross Paterson"
On Wed, Sep 11, 2002 at 07:51:40AM -0700, Sigbjorn Finne wrote:
Sorry about that, the intro'ed problem has now been cleared up, I believe.
But now module exports are broken:
module A(f) where f = id
module B(module A) where import A
module C where import B(f)
ERROR "C.hs" - Unknown entity "f" imported from module "B"

Thx - hopefully we're approaching a fixed point here..this
one was due to overzealously handling data constructors
in export lists (where they cannot appear in H98). This
interfered with type synonym exportation.
--sigbjorn
----- Original Message -----
From: "Ross Paterson"
On Wed, Sep 11, 2002 at 01:49:20PM -0700, Sigbjorn Finne wrote:
Thanks, now up tidied. Surprised this one wasn't caught by the regression tests.
Still a bit of this bug left, though it's hard to narrow down. Try loading ParsecPerm (old libs) or Text.ParserCombinators.Parsec.Perm.
participants (3)
-
Ross Paterson
-
Sigbjorn Finne
-
Simon Marlow