haskell-directory.git
18 years ago[project @ 2005-10-27 01:39:40 by sof]
sof [Thu, 27 Oct 2005 01:39:40 +0000 (01:39 +0000)]
[project @ 2005-10-27 01:39:40 by sof]
[mingw/msys only]
Undo long-standing workaround for buggy GNU ld's on mingw/msys; i.e.,
the linker wasn't correctly generating relocatable object files when
the number of relocs exceeded 2^16. Worked around the issue by
hackily splitting up the GHCi object file for the larger packages
('base', 'ObjectIO' and 'win32') into a handful of object files,
each with a manageable number of relocs. Tiresome and error-prone
(but the hack has served us well!)

This commit imposes a restriction on the 'ld' you use to compile
up GHC with; it now has to be ld-2.15.x or later (something GHC
binary dists have shipped with since 6.2.2)

18 years ago[project @ 2005-10-26 22:52:58 by ross]
ross [Wed, 26 Oct 2005 22:52:58 +0000 (22:52 +0000)]
[project @ 2005-10-26 22:52:58 by ross]
missing part of rev. 1.13: in unfoldForestM_BF, the output sequence is
now in the right order, so don't reverse it.

18 years ago[project @ 2005-10-25 17:31:38 by sof]
sof [Tue, 25 Oct 2005 17:31:38 +0000 (17:31 +0000)]
[project @ 2005-10-25 17:31:38 by sof]
FPTOOLS_CHECK_HTYPE: correctly scope the resetting of CPPFLAGS; as was,
it got blown away if the value was cached.

Merge to STABLE.

18 years ago[project @ 2005-10-25 12:01:11 by simonmar]
simonmar [Tue, 25 Oct 2005 12:01:11 +0000 (12:01 +0000)]
[project @ 2005-10-25 12:01:11 by simonmar]
fix findExecutable (I hope; don't have an up to date Windows build to
test on).

18 years ago[project @ 2005-10-25 11:13:53 by simonmar]
simonmar [Tue, 25 Oct 2005 11:13:53 +0000 (11:13 +0000)]
[project @ 2005-10-25 11:13:53 by simonmar]
forkIO the signal handlers directly from the IO manager thread, rather
than calling an RTS function to do the same thing.

18 years ago[project @ 2005-10-25 09:29:47 by ross]
ross [Tue, 25 Oct 2005 09:29:47 +0000 (09:29 +0000)]
[project @ 2005-10-25 09:29:47 by ross]
add Monoid instance

18 years ago[project @ 2005-10-25 09:29:16 by ross]
ross [Tue, 25 Oct 2005 09:29:16 +0000 (09:29 +0000)]
[project @ 2005-10-25 09:29:16 by ross]
Now that Data.Monoid is portable, move Monoid instances for sets and
maps back to where the data types are defined.

18 years ago[project @ 2005-10-25 09:11:25 by ross]
ross [Tue, 25 Oct 2005 09:11:25 +0000 (09:11 +0000)]
[project @ 2005-10-25 09:11:25 by ross]
Change the Monoid instance for functions (as proposed on the libraries
list, and interpreting silence as assent) from composition to pointwise
combination.

Rationale: The new instance is consistent with the instances for tuples,
it's compositional, in that it builds instances for complex types out
of instances for simpler ones, and it makes this module Haskell 98.

Downside: the old instance was easy to use with Writer monads, and ShowS
was a special case.  You can get that effect using the new Endo type,
but you have to wrap and unwrap the newtype.

Also added a few other simple monoids: dual, sum and product.

18 years ago[project @ 2005-10-25 09:01:48 by simonmar]
simonmar [Tue, 25 Oct 2005 09:01:48 +0000 (09:01 +0000)]
[project @ 2005-10-25 09:01:48 by simonmar]
Note that throwTo blocks if the target thread is in a foreign call.

18 years ago[project @ 2005-10-22 00:37:01 by ross]
ross [Sat, 22 Oct 2005 00:37:01 +0000 (00:37 +0000)]
[project @ 2005-10-22 00:37:01 by ross]
docs (readListDefault seems pretty useless)

18 years ago[project @ 2005-10-22 00:28:21 by ross]
ross [Sat, 22 Oct 2005 00:28:21 +0000 (00:28 +0000)]
[project @ 2005-10-22 00:28:21 by ross]
define readListPrec too.

18 years ago[project @ 2005-10-21 16:31:23 by ross]
ross [Fri, 21 Oct 2005 16:31:23 +0000 (16:31 +0000)]
[project @ 2005-10-21 16:31:23 by ross]
oops

18 years ago[project @ 2005-10-21 16:25:45 by ross]
ross [Fri, 21 Oct 2005 16:25:45 +0000 (16:25 +0000)]
[project @ 2005-10-21 16:25:45 by ross]
Data and FunctorM instances for View[LR].

18 years ago[project @ 2005-10-21 13:10:48 by simonmar]
simonmar [Fri, 21 Oct 2005 13:10:48 +0000 (13:10 +0000)]
[project @ 2005-10-21 13:10:48 by simonmar]
cmp_thread returns CInt, not Int

18 years ago[project @ 2005-10-21 10:47:25 by ross] cmm-merge2
ross [Fri, 21 Oct 2005 10:47:25 +0000 (10:47 +0000)]
[project @ 2005-10-21 10:47:25 by ross]
conformant Show and Read instances.

(sorry to jump in, JP, but I had these to hand)

18 years ago[project @ 2005-10-21 10:39:56 by ross]
ross [Fri, 21 Oct 2005 10:39:56 +0000 (10:39 +0000)]
[project @ 2005-10-21 10:39:56 by ross]
conformant Show and Read instances

18 years ago[project @ 2005-10-21 10:26:57 by ross]
ross [Fri, 21 Oct 2005 10:26:57 +0000 (10:26 +0000)]
[project @ 2005-10-21 10:26:57 by ross]
conformant Show and Read instances

18 years ago[project @ 2005-10-21 10:24:58 by ross]
ross [Fri, 21 Oct 2005 10:24:58 +0000 (10:24 +0000)]
[project @ 2005-10-21 10:24:58 by ross]
export parens, which is useful for writing Read instances.

18 years ago[project @ 2005-10-21 06:54:13 by ross]
ross [Fri, 21 Oct 2005 06:54:13 +0000 (06:54 +0000)]
[project @ 2005-10-21 06:54:13 by ross]
repair findExecutable

18 years ago[project @ 2005-10-20 23:28:42 by ross]
ross [Thu, 20 Oct 2005 23:28:42 +0000 (23:28 +0000)]
[project @ 2005-10-20 23:28:42 by ross]
revise Read instance to match < and > as chars rather than lexemes,
as suggested by Georg Martius.

18 years ago[project @ 2005-10-20 18:07:53 by krasimir]
krasimir [Thu, 20 Oct 2005 18:07:53 +0000 (18:07 +0000)]
[project @ 2005-10-20 18:07:53 by krasimir]
The original version of @findExecutable@ was looking only in the $PATH but under
Windows the executables are searched in the current directory, in $PATH and
in some other places too. The new version is based on @SearchPath@ function from
Win32 API. This is more consistent with @system@ and @rawSystem@

18 years ago[project @ 2005-10-20 17:12:28 by krasimir]
krasimir [Thu, 20 Oct 2005 17:12:28 +0000 (17:12 +0000)]
[project @ 2005-10-20 17:12:28 by krasimir]
from Neil Mitchell:

On Windows, the path can be path;"c:\ghc\ghc-6.4\bin";restofpath, and
thats still a valid path with GHC in it. Cabal doesn't find ghc with
the quotes in, removing them does find it though.

18 years ago[project @ 2005-10-20 15:14:22 by malcolm]
malcolm [Thu, 20 Oct 2005 15:14:22 +0000 (15:14 +0000)]
[project @ 2005-10-20 15:14:22 by malcolm]
Add spaces in Show instance, to avoid lexing problems e.g. Foo:=-0.9 in Read.

18 years ago[project @ 2005-10-20 15:08:35 by ross]
ross [Thu, 20 Oct 2005 15:08:35 +0000 (15:08 +0000)]
[project @ 2005-10-20 15:08:35 by ross]
Read instance

18 years ago[project @ 2005-10-20 10:58:44 by malcolm]
malcolm [Thu, 20 Oct 2005 10:58:44 +0000 (10:58 +0000)]
[project @ 2005-10-20 10:58:44 by malcolm]
Instance of Read for Map, from Georg Martius.

18 years ago[project @ 2005-10-18 11:36:25 by simonmar]
simonmar [Tue, 18 Oct 2005 11:36:25 +0000 (11:36 +0000)]
[project @ 2005-10-18 11:36:25 by simonmar]
Fixes to enable base to be compiled with -fasm on Windows:

  - a few stdcall/ccall mismatches
  - use GetTempPathA instead of GetTempPath (a couple of these)

18 years ago[project @ 2005-10-13 11:09:50 by ross]
ross [Thu, 13 Oct 2005 11:09:51 +0000 (11:09 +0000)]
[project @ 2005-10-13 11:09:50 by ross]
update non-portability reasons

18 years ago[project @ 2005-10-13 10:36:42 by ross]
ross [Thu, 13 Oct 2005 10:36:42 +0000 (10:36 +0000)]
[project @ 2005-10-13 10:36:42 by ross]
MArray instance for Lazy.ST

18 years ago[project @ 2005-10-13 10:35:49 by ross]
ross [Thu, 13 Oct 2005 10:35:49 +0000 (10:35 +0000)]
[project @ 2005-10-13 10:35:49 by ross]
comments re strict/lazy monads

18 years ago[project @ 2005-10-12 10:57:40 by simonpj]
simonpj [Wed, 12 Oct 2005 10:57:40 +0000 (10:57 +0000)]
[project @ 2005-10-12 10:57:40 by simonpj]
Comments

18 years ago[project @ 2005-10-10 23:32:51 by sof]
sof [Mon, 10 Oct 2005 23:32:51 +0000 (23:32 +0000)]
[project @ 2005-10-10 23:32:51 by sof]
CSsize fix: this Haskell type is defined iff HTYPE_SSIZE_T is. Merge to STABLE

18 years ago[project @ 2005-10-05 14:04:28 by simonmar]
simonmar [Wed, 5 Oct 2005 14:04:28 +0000 (14:04 +0000)]
[project @ 2005-10-05 14:04:28 by simonmar]
hPutChar should (probably) not be strict in its Char argument

18 years ago[project @ 2005-10-05 13:15:44 by simonmar]
simonmar [Wed, 5 Oct 2005 13:15:44 +0000 (13:15 +0000)]
[project @ 2005-10-05 13:15:44 by simonmar]
mention that -O turns assertions off

18 years ago[project @ 2005-10-05 08:43:26 by ross]
ross [Wed, 5 Oct 2005 08:43:26 +0000 (08:43 +0000)]
[project @ 2005-10-05 08:43:26 by ross]
add Monad and MonadPlus instances

18 years ago[project @ 2005-09-29 09:31:58 by ross]
ross [Thu, 29 Sep 2005 09:31:58 +0000 (09:31 +0000)]
[project @ 2005-09-29 09:31:58 by ross]
Tweak Read instance: allow optional parentheses around the outside
(for consistency), and don't propagate precedence to elements.

18 years ago[project @ 2005-09-28 13:18:28 by malcolm]
malcolm [Wed, 28 Sep 2005 13:18:28 +0000 (13:18 +0000)]
[project @ 2005-09-28 13:18:28 by malcolm]
Add an instance of Read to correspond to the existing Show instance.
(Implementation based on H'98 Report definition of 'readList'.)

18 years ago[project @ 2005-09-24 15:07:49 by panne]
panne [Sat, 24 Sep 2005 15:07:49 +0000 (15:07 +0000)]
[project @ 2005-09-24 15:07:49 by panne]
Synched all FPTOOLS_CHECK_HTYPE definitions with the latest changes in
libraries/OpenAL/aclocal.m4. Although it is not strictly necessary, keeping
things identical is good for consistency. At some point in time we should
really find a way to eliminate all this redundancy... *sigh*

18 years ago[project @ 2005-09-22 09:43:01 by ross]
ross [Thu, 22 Sep 2005 09:43:01 +0000 (09:43 +0000)]
[project @ 2005-09-22 09:43:01 by ross]
some docs

18 years ago[project @ 2005-09-21 11:54:59 by simonmar]
simonmar [Wed, 21 Sep 2005 11:54:59 +0000 (11:54 +0000)]
[project @ 2005-09-21 11:54:59 by simonmar]
improve documentation for getProcessExitCode

18 years ago[project @ 2005-09-19 23:24:31 by ross]
ross [Mon, 19 Sep 2005 23:24:31 +0000 (23:24 +0000)]
[project @ 2005-09-19 23:24:31 by ross]
For compilers other than MSVC and GCC, assume inline has the C99 semantics.

18 years ago[project @ 2005-09-18 10:01:57 by panne]
panne [Sun, 18 Sep 2005 10:01:57 +0000 (10:01 +0000)]
[project @ 2005-09-18 10:01:57 by panne]
Fixed a few underquoted definitions.

18 years ago[project @ 2005-09-18 02:22:33 by dons]
dons [Sun, 18 Sep 2005 02:22:33 +0000 (02:22 +0000)]
[project @ 2005-09-18 02:22:33 by dons]
Typo in comment only. Spotted by heatsink on #haskell.

18 years ago[project @ 2005-09-02 14:04:38 by simonmar]
simonmar [Fri, 2 Sep 2005 14:04:38 +0000 (14:04 +0000)]
[project @ 2005-09-02 14:04:38 by simonmar]
back out rev. 1.22; as pointed out by Krasimir Angelov, the
optimisation doesn't work (sadly).

18 years ago[project @ 2005-09-01 10:49:07 by ross]
ross [Thu, 1 Sep 2005 10:49:07 +0000 (10:49 +0000)]
[project @ 2005-09-01 10:49:07 by ross]
GHC only: define toList using build

18 years ago[project @ 2005-08-31 12:15:31 by ross]
ross [Wed, 31 Aug 2005 12:15:31 +0000 (12:15 +0000)]
[project @ 2005-08-31 12:15:31 by ross]
Hugs: use custom versioon of unsafeInterleaveIO

18 years ago[project @ 2005-08-05 09:48:16 by ross]
ross [Fri, 5 Aug 2005 09:48:16 +0000 (09:48 +0000)]
[project @ 2005-08-05 09:48:16 by ross]
haddock stuff

18 years ago[project @ 2005-08-04 11:40:26 by simonmar]
simonmar [Thu, 4 Aug 2005 11:40:26 +0000 (11:40 +0000)]
[project @ 2005-08-04 11:40:26 by simonmar]
fix typo in subRegex (fixes subRegex breakage on Windows)

18 years ago[project @ 2005-08-01 13:23:22 by simonmar]
simonmar [Mon, 1 Aug 2005 13:23:22 +0000 (13:23 +0000)]
[project @ 2005-08-01 13:23:22 by simonmar]
Fix

  [ ghc-Bugs-1249226 ] runInteractiveProcess and closed stdin.

18 years ago[project @ 2005-07-29 17:17:22 by ross]
ross [Fri, 29 Jul 2005 17:17:22 +0000 (17:17 +0000)]
[project @ 2005-07-29 17:17:22 by ross]
document deprecation

18 years ago[project @ 2005-07-29 17:03:37 by ross]
ross [Fri, 29 Jul 2005 17:03:37 +0000 (17:03 +0000)]
[project @ 2005-07-29 17:03:37 by ross]
deprecate in favour of Data.Sequence

18 years ago[project @ 2005-07-29 17:02:07 by ross]
ross [Fri, 29 Jul 2005 17:02:07 +0000 (17:02 +0000)]
[project @ 2005-07-29 17:02:07 by ross]
use Data.Sequence instead of Data.Queue

18 years ago[project @ 2005-07-28 13:27:03 by ross]
ross [Thu, 28 Jul 2005 13:27:03 +0000 (13:27 +0000)]
[project @ 2005-07-28 13:27:03 by ross]
avoid warnings

18 years ago[project @ 2005-07-27 10:04:26 by simonmar]
simonmar [Wed, 27 Jul 2005 10:04:26 +0000 (10:04 +0000)]
[project @ 2005-07-27 10:04:26 by simonmar]
expand docs for touchForeignPtr and newConcForeignPtr

18 years ago[project @ 2005-07-27 00:52:33 by ross]
ross [Wed, 27 Jul 2005 00:52:33 +0000 (00:52 +0000)]
[project @ 2005-07-27 00:52:33 by ross]
Hugs only: no longer need backslash fiddle now that Hugs leaves them alone.

18 years ago[project @ 2005-07-26 11:00:42 by ross]
ross [Tue, 26 Jul 2005 11:00:42 +0000 (11:00 +0000)]
[project @ 2005-07-26 11:00:42 by ross]
this version of closeFd is used by GHC only

18 years ago[project @ 2005-07-26 09:37:27 by ross]
ross [Tue, 26 Jul 2005 09:37:28 +0000 (09:37 +0000)]
[project @ 2005-07-26 09:37:27 by ross]
PrelHandle functions are only needed by GHC

18 years ago[project @ 2005-07-23 17:08:03 by ross]
ross [Sat, 23 Jul 2005 17:08:03 +0000 (17:08 +0000)]
[project @ 2005-07-23 17:08:03 by ross]
non-GHC: implement rawSystem by translating the string for system.

18 years ago[project @ 2005-07-23 13:28:24 by ross]
ross [Sat, 23 Jul 2005 13:28:24 +0000 (13:28 +0000)]
[project @ 2005-07-23 13:28:24 by ross]
Hugs: omit commandToProcess

18 years ago[project @ 2005-07-22 16:25:16 by ross]
ross [Fri, 22 Jul 2005 16:25:16 +0000 (16:25 +0000)]
[project @ 2005-07-22 16:25:16 by ross]
revert 1.17

18 years ago[project @ 2005-07-22 10:18:51 by simonmar]
simonmar [Fri, 22 Jul 2005 10:18:51 +0000 (10:18 +0000)]
[project @ 2005-07-22 10:18:51 by simonmar]
check the return value of chdir()

  [ 1242598 ] runProcess uses cwd for bad working directory argument

18 years ago[project @ 2005-07-22 08:15:06 by ross]
ross [Fri, 22 Jul 2005 08:15:06 +0000 (08:15 +0000)]
[project @ 2005-07-22 08:15:06 by ross]
unbreak for non-GHC

18 years ago[project @ 2005-07-21 12:54:33 by simonmar]
simonmar [Thu, 21 Jul 2005 12:54:33 +0000 (12:54 +0000)]
[project @ 2005-07-21 12:54:33 by simonmar]
Hack Makefiles so that 'make distclean' works even if the tree has not
been configured, or 'make distclean' has already been run.

This is to solve problems caused by 'make distclean' removing files
that it needs itself - previously we were arranging to remove certain
files right at the end of cleaning, but this is fragile.  So now we
assume that e.g. the X11 library is always enabled when we're
cleaning.

18 years ago[project @ 2005-07-21 11:08:51 by ross]
ross [Thu, 21 Jul 2005 11:08:51 +0000 (11:08 +0000)]
[project @ 2005-07-21 11:08:51 by ross]
specialize instances too

18 years ago[project @ 2005-07-21 11:00:17 by ross]
ross [Thu, 21 Jul 2005 11:00:17 +0000 (11:00 +0000)]
[project @ 2005-07-21 11:00:17 by ross]
revise Data instance again, making it like lists

18 years ago[project @ 2005-07-21 10:59:27 by ross]
ross [Thu, 21 Jul 2005 10:59:27 +0000 (10:59 +0000)]
[project @ 2005-07-21 10:59:27 by ross]
more SPECIALIZE pragmas

18 years ago[project @ 2005-07-21 10:00:34 by simonmar]
simonmar [Thu, 21 Jul 2005 10:00:34 +0000 (10:00 +0000)]
[project @ 2005-07-21 10:00:34 by simonmar]
Further optimisations to ForeignPtr: now we don't allocate the IORef
for a ForeignPtr without a finalizer.

18 years ago[project @ 2005-07-21 09:26:30 by simonmar]
simonmar [Thu, 21 Jul 2005 09:26:30 +0000 (09:26 +0000)]
[project @ 2005-07-21 09:26:30 by simonmar]
copyFile: copy the permissions properly (don't use getPermissions >>=
setPermissions, which only copies the owner's permissions on Unix).

18 years ago[project @ 2005-07-19 23:22:39 by ross]
ross [Tue, 19 Jul 2005 23:22:39 +0000 (23:22 +0000)]
[project @ 2005-07-19 23:22:39 by ross]
use feature tests instead of $host to locate socket library

18 years ago[project @ 2005-07-19 17:33:23 by ross]
ross [Tue, 19 Jul 2005 17:33:23 +0000 (17:33 +0000)]
[project @ 2005-07-19 17:33:23 by ross]
improved definition of gfold for Seq a

18 years ago[project @ 2005-07-19 17:06:18 by ross]
ross [Tue, 19 Jul 2005 17:06:18 +0000 (17:06 +0000)]
[project @ 2005-07-19 17:06:18 by ross]
hook in Data.Sequence

18 years ago[project @ 2005-07-19 09:26:03 by ross]
ross [Tue, 19 Jul 2005 09:26:03 +0000 (09:26 +0000)]
[project @ 2005-07-19 09:26:03 by ross]
use $host instead of $target (mainly affects builds with cabal)

18 years ago[project @ 2005-07-14 15:36:31 by ross]
ross [Thu, 14 Jul 2005 15:36:32 +0000 (15:36 +0000)]
[project @ 2005-07-14 15:36:31 by ross]
remove redundant definitions of unsafeRangeSize (same as default)

18 years ago[project @ 2005-07-14 11:59:27 by ross]
ross [Thu, 14 Jul 2005 11:59:27 +0000 (11:59 +0000)]
[project @ 2005-07-14 11:59:27 by ross]
Data.Sequence: general purpose finite sequences
(as discussed on the libraries list in May 2005).

18 years ago[project @ 2005-07-14 11:57:09 by ross]
ross [Thu, 14 Jul 2005 11:57:09 +0000 (11:57 +0000)]
[project @ 2005-07-14 11:57:09 by ross]
Hugs only: more specific imports

18 years ago[project @ 2005-07-10 23:01:24 by ross]
ross [Sun, 10 Jul 2005 23:01:24 +0000 (23:01 +0000)]
[project @ 2005-07-10 23:01:24 by ross]
doc fix from Remi Turk

MERGE to STABLE

18 years ago[project @ 2005-07-08 17:17:31 by sof]
sof [Fri, 8 Jul 2005 17:17:31 +0000 (17:17 +0000)]
[project @ 2005-07-08 17:17:31 by sof]
- System.Posix.Internals.FDType.RawDevice: new constructor.
- System.Posix.Internals.fdType: map block devices to RawDevice
  (but left character devices as still being Streams).
- GHC.IOBase.isReadWriteHandleType: new HandleType predicate.
- GHC.Handle.hIsSeekable: RawDevices are seekable.
- GHC.Handle.openFd: handle RawDevices.
   => opening of block devices via std IO opening actions
      (open{Binary}File, openFd etc.) should now work better.

Merge to STABLE.

18 years ago[project @ 2005-07-08 13:17:47 by simonmar]
simonmar [Fri, 8 Jul 2005 13:17:47 +0000 (13:17 +0000)]
[project @ 2005-07-08 13:17:47 by simonmar]
oops, fix imports

18 years ago[project @ 2005-07-08 12:22:02 by simonmar]
simonmar [Fri, 8 Jul 2005 12:22:02 +0000 (12:22 +0000)]
[project @ 2005-07-08 12:22:02 by simonmar]
Fix instance Eq Version

18 years ago[project @ 2005-07-06 16:17:36 by malcolm]
malcolm [Wed, 6 Jul 2005 16:17:36 +0000 (16:17 +0000)]
[project @ 2005-07-06 16:17:36 by malcolm]
Fix (from Scott Turner) for a broken implementation of 'split'.

18 years ago[project @ 2005-07-06 12:25:53 by simonmar]
simonmar [Wed, 6 Jul 2005 12:25:53 +0000 (12:25 +0000)]
[project @ 2005-07-06 12:25:53 by simonmar]
runProcess: allow duplicate Handles to be passed in without deadlock.
Fixes #1187295.

18 years ago[project @ 2005-07-06 12:13:04 by simonmar]
simonmar [Wed, 6 Jul 2005 12:13:04 +0000 (12:13 +0000)]
[project @ 2005-07-06 12:13:04 by simonmar]
Close Handles passed to runProcess.  Fixes #1187302

18 years ago[project @ 2005-07-04 10:22:17 by ross]
ross [Mon, 4 Jul 2005 10:22:17 +0000 (10:22 +0000)]
[project @ 2005-07-04 10:22:17 by ross]
add Typeable instance

18 years ago[project @ 2005-06-27 22:31:41 by simonmar]
simonmar [Mon, 27 Jun 2005 22:31:41 +0000 (22:31 +0000)]
[project @ 2005-06-27 22:31:41 by simonmar]
As discussed on ghc-users some time ago, optimise the representation
of ForeignPtr to make withForeignPtr more efficient.  ForeignPtr is
now represented by a pair of an Addr# and a ForeignPtrContents object.

withForeignPtr just extracts the Addr# and touches the
ForeignPtrContents.

ForeignPtr no longer uses the primitive ForeignObj# type: it isn't
required, since we attach the finalizer to the IORef inside
ForeignPtrContents now.  In fact, the ForeignObj# type is now
obsolete, and can be removed.

18 years ago[project @ 2005-06-27 13:56:32 by simonmar]
simonmar [Mon, 27 Jun 2005 13:56:32 +0000 (13:56 +0000)]
[project @ 2005-06-27 13:56:32 by simonmar]
Fix performance buglet: small Float literals weren't being simplified
enough because the fromInteger method is defined in terms of
encodeFloat, which itself is an FFI call.  Double was already fixed,
this change does the right thing for Float too.

18 years ago[project @ 2005-06-10 13:21:52 by simonpj]
simonpj [Fri, 10 Jun 2005 13:21:52 +0000 (13:21 +0000)]
[project @ 2005-06-10 13:21:52 by simonpj]
Make toConstr strict for tuples, so that it's uniform with
all other data types.

This inconsistency is really a bug:
MERGE to STABLE

18 years ago[project @ 2005-06-10 13:19:41 by simonpj]
simonpj [Fri, 10 Jun 2005 13:19:41 +0000 (13:19 +0000)]
[project @ 2005-06-10 13:19:41 by simonpj]
Eta-contract foldr/app RULE to avoid overlap with foldr/id

18 years ago[project @ 2005-05-27 19:26:34 by simonmar]
simonmar [Fri, 27 May 2005 19:26:34 +0000 (19:26 +0000)]
[project @ 2005-05-27 19:26:34 by simonmar]
hLookAhead: don't wait for a completely full buffer

19 years ago[project @ 2005-05-13 16:58:02 by sof]
sof [Fri, 13 May 2005 16:58:02 +0000 (16:58 +0000)]
[project @ 2005-05-13 16:58:02 by sof]
flush_input_console__(): if the fd isn't connected to a console, treat flush as a NOP. Merge to STABLE.

19 years ago[project @ 2005-05-06 00:30:56 by sof]
sof [Fri, 6 May 2005 00:30:57 +0000 (00:30 +0000)]
[project @ 2005-05-06 00:30:56 by sof]
[mingw only]
Work around bug in win32 Console API which showed up in the GHCi UI:
if the user typed in characters prior to the appearance of the prompt,
the first of these characters always came out as a 'g'. The GHCi UI does
for good reasons one-character reads from 'stdin', which causes the
underlying APIs to become confused. A simple repro case is the following
piece of C code:

/*----------------------*/
#include <stdio.h>
#include <windows.h>
int main()
{
    char ch1,ch2;
    HANDLE hStdIn = GetStdHandle(STD_INPUT_HANDLE);
    DWORD dw;

    /* Type in some characters before the prompt appears and be amused.. */
    sleep(1000); printf("? ");
    ReadConsoleA(hStdIn,&ch1,1,&dw,NULL);
    ReadConsoleA(hStdIn,&ch2,1,&dw,NULL);
/*  or, if you want to use libc:
    read(0,&ch1,1); read(0,&ch2,1); */

    printf("%c%c\n", ch1,ch2);
    return 0;
}
/*----------------------*/

This happens across win32 OSes, and I can't see anything untoward as far
as API usage goes (the GHC IO implementation uses read(), but that
reduces to ReadConsoleA() calls.) People inside the Behemoth might want
to have a closer look at this..

Not much we can do about this except work around the problem by flushing
the input buffer prior to reading from stdin. Not ideal, as type-ahead
is a useful feature. Flushing is handled by GHC.ConsoleHandler.flushConsole

Merge to STABLE.

19 years ago[project @ 2005-05-04 15:07:47 by simonmar]
simonmar [Wed, 4 May 2005 15:07:47 +0000 (15:07 +0000)]
[project @ 2005-05-04 15:07:47 by simonmar]
Do *not* inline runSTRep now (see comments for details).

19 years ago[project @ 2005-04-25 13:25:08 by simonmar] arity-anal-branch-point
simonmar [Mon, 25 Apr 2005 13:25:08 +0000 (13:25 +0000)]
[project @ 2005-04-25 13:25:08 by simonmar]
Only ftruncate() regular files.

19 years ago[project @ 2005-04-22 17:00:49 by sof]
sof [Fri, 22 Apr 2005 17:00:49 +0000 (17:00 +0000)]
[project @ 2005-04-22 17:00:49 by sof]
[mingw only]
Better handling of I/O request abortions upon throwing an exception
to a Haskell thread. As was, a thread blocked on an I/O request was
simply unblocked, but its corresponding worker thread wasn't notified
that the request had been abandoned.

This manifested itself in GHCi upon Ctrl-C being hit at the prompt -- the
worker thread blocked waiting for input on stdin prior to Ctrl-C would
stick around even though its corresponding Haskell thread had been
thrown an Interrupted exception. The upshot was that the worker would
consume the next character typed in after Ctrl-C, but then just dropping
it. Dealing with this turned out to be even more interesting due to
Win32 aborting any console reads when Ctrl-C/Break events are delivered.

The story could be improved upon (at the cost of portability) by making
the Scheduler able to abort worker thread system calls; as is, requests
are cooperatively abandoned. Maybe later.

Also included are other minor tidyups to Ctrl-C handling under mingw.

Merge to STABLE.

19 years ago[project @ 2005-04-22 16:07:36 by sof]
sof [Fri, 22 Apr 2005 16:07:36 +0000 (16:07 +0000)]
[project @ 2005-04-22 16:07:36 by sof]
make DEBUG_DUMP-conditional code compile

19 years ago[project @ 2005-04-21 09:40:41 by simonmar]
simonmar [Thu, 21 Apr 2005 09:40:41 +0000 (09:40 +0000)]
[project @ 2005-04-21 09:40:41 by simonmar]
Add unsafeForeignPtrToStorableArray

19 years ago[project @ 2005-04-17 10:06:16 by panne]
panne [Sun, 17 Apr 2005 10:06:16 +0000 (10:06 +0000)]
[project @ 2005-04-17 10:06:16 by panne]
Merged "unrecoginzed long opt" fix from Distribution.GetOpt

MERGE TO STABLE

19 years ago[project @ 2005-04-12 12:57:49 by ross]
ross [Tue, 12 Apr 2005 12:57:49 +0000 (12:57 +0000)]
[project @ 2005-04-12 12:57:49 by ross]
clarify docs of insert and union.

(for STABLE)

19 years ago[project @ 2005-04-07 23:36:48 by sof]
sof [Thu, 7 Apr 2005 23:36:48 +0000 (23:36 +0000)]
[project @ 2005-04-07 23:36:48 by sof]
import reordering wibble to make it mingw-palatable.

Merge to STABLE.

19 years ago[project @ 2005-04-07 14:33:31 by simonmar]
simonmar [Thu, 7 Apr 2005 14:33:32 +0000 (14:33 +0000)]
[project @ 2005-04-07 14:33:31 by simonmar]
Support handling signals in the threaded RTS by passing the signal
number down the pipe to the IO manager.  This avoids needing
synchronisation in the signal handler.

Signals should now work with -threaded.  Since this is a bugfix, I'll
merge the changes into the 6.4 branch.

19 years ago[project @ 2005-04-06 22:05:58 by simonmar]
simonmar [Wed, 6 Apr 2005 22:05:58 +0000 (22:05 +0000)]
[project @ 2005-04-06 22:05:58 by simonmar]
Fix bug in hDuplicateTo

MERGE TO STABLE

19 years ago[project @ 2005-04-05 08:38:24 by simonmar]
simonmar [Tue, 5 Apr 2005 08:38:24 +0000 (08:38 +0000)]
[project @ 2005-04-05 08:38:24 by simonmar]
Determine the location of CMD.EXE (or COMMAND.COM) using the same
algorithm as system() from msvcrt.