Heya Ludo,
On Fri 15 Apr 2011 23:44, [email protected] (Ludovic Courtès) writes:
>> For example in the following program:
>>
>> void* thread (void*)
>> {
>> scm_with_guile (do_something, NULL);
>> scm_with_guile (do_something_else, NULL);
>> return NULL;
>> }
>>
>> int main ()
>> {
>> pthread_t thr;
>> pthread_create (&thr, NULL, thread, NULL);
>> pthread_join (thr, NULL);
>> return 0;
>> }
>>
>> When do you propose that the cleanup handlers for the thread be called?
>
> I’ll followup on this later, but currently it seems impossible to call
> GC_INIT from a thread other than the initial thread [0].
Interesting; I had it working at some point, in the context of that
other bug; anyway, the same considerations hold if you scm_init_guile
in the main thread first.
Cheers,
Andy
--
http://wingolog.org/