]> Cypherpunks repositories - gostls13.git/commitdiff
fix for broken build (built-in new was invisible due to a parameter called 'new')
authorRobert Griesemer <gri@golang.org>
Tue, 24 Nov 2009 22:11:53 +0000 (14:11 -0800)
committerRobert Griesemer <gri@golang.org>
Tue, 24 Nov 2009 22:11:53 +0000 (14:11 -0800)
R=iant
https://golang.org/cl/160057

src/pkg/debug/proc/proc_linux.go

index 28b85dcdffa0e76700d6f6306520e61d6df3d398..c17e6855b882e29ac041f9b02420bcd97ce0dcd1 100644 (file)
@@ -456,12 +456,12 @@ func (t *thread) wait() {
 // necessary, and invokes state transition handlers.
 //
 // Must be called from the monitor thread.
-func (t *thread) setState(new threadState) {
-       old := t.state;
-       t.state = new;
-       t.logTrace("state %v -> %v", old, new);
+func (t *thread) setState(newState threadState) {
+       oldState := t.state;
+       t.state = newState;
+       t.logTrace("state %v -> %v", oldState, newState);
 
-       if !old.isRunning() && (new.isRunning() || new.isZombie()) {
+       if !oldState.isRunning() && (newState.isRunning() || newState.isZombie()) {
                // Start waiting on this thread
                go t.wait()
        }
@@ -475,7 +475,7 @@ func (t *thread) setState(new threadState) {
        t.proc.transitionHandlers = new(vector.Vector);
        for _, h := range handlers.Data() {
                h := h.(*transitionHandler);
-               h.handle(t, old, new);
+               h.handle(t, oldState, newState);
        }
 }