In the file /usr/local/go/src/syscall/dll_windows.go:300

Is there any use case to use the always non-nil error obj?

That is a strange design.I think I need to write my version of LazyProc.

I can write something like following to work around this:

func IsSyscallErrorHappen(err error) bool{
   if err==nil{
      return false
   }
   errNo,ok:=err.(syscall.Errno)
   if ok && errNo==0{
      return false
   }
   return true
}

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to