scsh-checkins
[Top] [All Lists]

[Scsh-checkins] CVS: scsh-0.6/scheme/rts thread.scm,1.2,1.3

To: scsh-checkins@lists.sourceforge.net
Subject: [Scsh-checkins] CVS: scsh-0.6/scheme/rts thread.scm,1.2,1.3
From: Mike Sperber <sperber@users.sourceforge.net>
Date: Mon, 28 May 2001 06:31:03 -0700
List-id: <scsh-checkins.lists.sourceforge.net>
Sender: scsh-checkins-admin@lists.sourceforge.net
Update of /cvsroot/scsh/scsh-0.6/scheme/rts
In directory usw-pr-cvs1:/tmp/cvs-serv12114

Modified Files:
        thread.scm 
Log Message:
Bug fix:
I had forgotten to mark the thread-cell value environment as read-only
when it's passed on to a spawned thread.  Do that now.


Index: thread.scm
===================================================================
RCS file: /cvsroot/scsh/scsh-0.6/scheme/rts/thread.scm,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** thread.scm  2001/05/22 14:58:15     1.2
--- thread.scm  2001/05/28 13:31:01     1.3
***************
*** 550,553 ****
--- 550,554 ----
  
  (define (spawn thunk . id)
+   (set-thread-own-values?! (current-thread) #f)
    (apply spawn-on-scheduler
         (thread-scheduler (current-thread))
***************
*** 558,566 ****
  (define (spawn-on-root thunk . id)
    (if (root-scheduler)
!       (apply spawn-on-scheduler
!            (root-scheduler)
!            thunk
!            (thread-cell-values (current-thread))
!            id)
        (thunk)))
  
--- 559,569 ----
  (define (spawn-on-root thunk . id)
    (if (root-scheduler)
!       (begin
!       (set-thread-own-values?! (current-thread) #f)
!       (apply spawn-on-scheduler
!              (root-scheduler)
!              thunk
!              (thread-cell-values (current-thread))
!              id))
        (thunk)))
  



<Prev in Thread] Current Thread [Next in Thread>
  • [Scsh-checkins] CVS: scsh-0.6/scheme/rts thread.scm,1.2,1.3, Mike Sperber <=