Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Shayne Fletcher
Glasgow Haskell Compiler
Commits
0491574d
Commit
0491574d
authored
Dec 10, 1999
by
simonmar
Browse files
[project @ 1999-12-10 15:50:10 by simonmar]
Unbreak finalization.
parent
5204750a
Changes
1
Hide whitespace changes
Inline
Side-by-side
ghc/rts/Weak.c
View file @
0491574d
/* -----------------------------------------------------------------------------
/* -----------------------------------------------------------------------------
* $Id: Weak.c,v 1.1
1
1999/
07/06 15:05:49 sof
Exp $
* $Id: Weak.c,v 1.1
2
1999/
12/10 15:50:10 simonmar
Exp $
*
*
* (c) The GHC Team, 1998-1999
* (c) The GHC Team, 1998-1999
*
*
...
@@ -58,15 +58,17 @@ void
...
@@ -58,15 +58,17 @@ void
scheduleFinalizers
(
StgWeak
*
list
)
scheduleFinalizers
(
StgWeak
*
list
)
{
{
StgWeak
*
w
;
StgWeak
*
w
;
StgTSO
*
t
;
for
(
w
=
list
;
w
;
w
=
w
->
link
)
{
for
(
w
=
list
;
w
;
w
=
w
->
link
)
{
IF_DEBUG
(
weak
,
fprintf
(
stderr
,
"Finalising weak pointer at %p -> %p
\n
"
,
w
,
w
->
key
));
IF_DEBUG
(
weak
,
fprintf
(
stderr
,
"Finalising weak pointer at %p -> %p
\n
"
,
w
,
w
->
key
));
if
(
w
->
finalizer
!=
&
NO_FINALIZER_closure
)
{
if
(
w
->
finalizer
!=
&
NO_FINALIZER_closure
)
{
#ifdef INTERPRETER
#ifdef INTERPRETER
createGenThread
(
RtsFlags
.
GcFlags
.
initialStkSize
,
w
->
finalizer
);
t
=
createGenThread
(
RtsFlags
.
GcFlags
.
initialStkSize
,
w
->
finalizer
);
#else
#else
createIOThread
(
RtsFlags
.
GcFlags
.
initialStkSize
,
w
->
finalizer
);
t
=
createIOThread
(
RtsFlags
.
GcFlags
.
initialStkSize
,
w
->
finalizer
);
#endif
#endif
scheduleThread
(
t
);
}
}
w
->
header
.
info
=
&
DEAD_WEAK_info
;
w
->
header
.
info
=
&
DEAD_WEAK_info
;
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment