diff options
| author | Simon Marlow <simonmar@microsoft.com> | 2006-03-17 15:47:34 +0000 |
|---|---|---|
| committer | Simon Marlow <simonmar@microsoft.com> | 2006-03-17 15:47:34 +0000 |
| commit | fa9c11a2ca53679eec55187e45dd9c895f48251a (patch) | |
| tree | b55d09ae41a35290490f582245bfddd13f8efe60 /ghc/rts/Task.c | |
| parent | e6218fe7eff4e34e1a3c823cd4b7aebe09d2d4fb (diff) | |
| download | haskell-fa9c11a2ca53679eec55187e45dd9c895f48251a.tar.gz | |
fix build for certain picky versions of gcc
Diffstat (limited to 'ghc/rts/Task.c')
| -rw-r--r-- | ghc/rts/Task.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/ghc/rts/Task.c b/ghc/rts/Task.c index 89db782800..7366480094 100644 --- a/ghc/rts/Task.c +++ b/ghc/rts/Task.c @@ -171,18 +171,18 @@ boundTaskExiting (Task *task) IF_DEBUG(scheduler,sched_belch("task exiting")); } +#ifdef THREADED_RTS +#define TASK_ID(t) (t)->id +#else +#define TASK_ID(t) (t) +#endif + void discardTask (Task *task) { ASSERT_LOCK_HELD(&sched_mutex); if (!task->stopped) { - IF_DEBUG(scheduler,sched_belch("discarding task %p", -#ifdef THREADED_RTS - (void *)task->id -#else - (void *)task -#endif - )); + IF_DEBUG(scheduler,sched_belch("discarding task %p", TASK_ID(task))); task->cap = NULL; task->tso = NULL; task->stopped = rtsTrue; |
