[commit: base] master: Tweak alloca docs (83f2740)
Ian Lynagh
igloo at earth.li
Sun Apr 3 17:37:21 CEST 2011
Repository : ssh://darcs.haskell.org//srv/darcs/packages/base
On branch : master
http://hackage.haskell.org/trac/ghc/changeset/83f2740e7b4132594dbe5b0ab458fbdf3f197ffb
>---------------------------------------------------------------
commit 83f2740e7b4132594dbe5b0ab458fbdf3f197ffb
Author: Ian Lynagh <igloo at earth.li>
Date: Sun Apr 3 16:27:56 2011 +0100
Tweak alloca docs
Based on a patch from Jason Dagit
>---------------------------------------------------------------
Foreign/Marshal/Alloc.hs | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/Foreign/Marshal/Alloc.hs b/Foreign/Marshal/Alloc.hs
index ddb4a90..612d2c7 100644
--- a/Foreign/Marshal/Alloc.hs
+++ b/Foreign/Marshal/Alloc.hs
@@ -22,8 +22,9 @@
-- foreign functions or to provide space in which compound result values
-- are obtained from foreign functions.
--
--- If any of the allocation functions fails, a value of 'nullPtr' is
--- produced. If 'free' or 'reallocBytes' is applied to a memory area
+-- If any of the allocation functions fails, an exception is thrown.
+-- In some cases, memory exhaustion may mean the process is terminated.
+-- If 'free' or 'reallocBytes' is applied to a memory area
-- that has been allocated with 'alloca' or 'allocaBytes', the
-- behaviour is undefined. Any further access to memory areas allocated with
-- 'alloca' or 'allocaBytes', after the computation that was passed to
More information about the Libraries
mailing list