On Thu, Apr 27, 2017 at 11:18 PM, hui zhang wrote:
>
> How let go and c code work Alternately in the same thread with
> goroutine(corouting mechanism)
I'm not sure but I think you may be looking for
https://golang.org/pkg/runtime/#LockOSThread .
Ian
--
You received this message because you are
How let go and c code work Alternately in the same thread with
goroutine(corouting mechanism)
Check the code below. c and go code in one thread they just do work 1 by 1.
Expected Result
> Do CWork
> Do GoWork
> Do CWork
> Do GoWork
> Do CWork
> .
//c code
> void CWork() {
> while(1) {
>