Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- func (vm *VM) newThread() *thread {
- s := &stack{RWMutex: new(sync.RWMutex)}
- cfs := &callFrameStack{callFrames: []callFrame{}}
- t := &thread{stack: s, callFrameStack: cfs, sp: 0, cfp: 0}
- s.thread = t
- cfs.thread = t
- t.vm = vm
- return t
- }
Add Comment
Please, Sign In to add comment