diff options
author | sewardj <unknown> | 2001-12-20 16:12:09 +0000 |
---|---|---|
committer | sewardj <unknown> | 2001-12-20 16:12:09 +0000 |
commit | 791d890ca039ce45704b879b292069ddc5821dc0 (patch) | |
tree | 6e5cc00fcdc0c068815eae5261e15ccec07bf352 /ghc/includes/Stable.h | |
parent | 0cc54eac4ab05b44ddab78d1531ccb9edc5d7e6c (diff) | |
download | haskell-791d890ca039ce45704b879b292069ddc5821dc0.tar.gz |
[project @ 2001-12-20 16:12:09 by sewardj]
Outline freeStablePtr, so NCG-generated code actually has something to call :)
Also remove the presumably-defunct splitStablePtr.
Diffstat (limited to 'ghc/includes/Stable.h')
-rw-r--r-- | ghc/includes/Stable.h | 23 |
1 files changed, 3 insertions, 20 deletions
diff --git a/ghc/includes/Stable.h b/ghc/includes/Stable.h index 28227ec6e6..12056f9974 100644 --- a/ghc/includes/Stable.h +++ b/ghc/includes/Stable.h @@ -1,5 +1,5 @@ /* ----------------------------------------------------------------------------- - * $Id: Stable.h,v 1.11 2001/12/12 14:03:30 simonmar Exp $ + * $Id: Stable.h,v 1.12 2001/12/20 16:12:09 sewardj Exp $ * * (c) The GHC Team, 1998-2000 * @@ -42,31 +42,14 @@ extern DLL_IMPORT_RTS snEntry *stable_ptr_free; extern DLL_IMPORT_RTS unsigned int SPT_size; +extern void freeStablePtr(StgStablePtr sp); + extern inline StgPtr deRefStablePtr(StgStablePtr sp) { ASSERT(stable_ptr_table[(StgWord)sp].ref > 0); return stable_ptr_table[(StgWord)sp].addr; } - -extern inline void -freeStablePtr(StgStablePtr sp) -{ - StgWord sn = (StgWord)sp; - - ASSERT(sn < SPT_size - && stable_ptr_table[sn].addr != NULL - && stable_ptr_table[sn].ref > 0); - - stable_ptr_table[sn].ref --; -} - -extern inline StgStablePtr -splitStablePtr(StgStablePtr sp) -{ - stable_ptr_table[(StgWord)sp].ref ++; - return sp; -} /* No deRefStableName, because the existence of a stable name doesn't * guarantee the existence of the object itself. |