Revert "refactor(c/libuv): Use cgo alias replace struct assertion in fs"

This reverts commit 45ba5b8dc50a13223e05ad673f4e57d7277d3f24.

# Conflicts:
#	c/libuv/net.go
This commit is contained in:
hackerchai
2024-08-07 12:03:28 +08:00
parent dd93a97790
commit 3cd62994c7
2 changed files with 8 additions and 5 deletions

View File

@@ -1,9 +1,5 @@
package libuv
//#cgo pkg-config: libuv
//#include <uv.h>
import "C"
import (
_ "unsafe"
@@ -72,7 +68,9 @@ type File c.Int
/* Handle types. */
type Fs C.uv_fs_t
type Fs struct {
Unused [440]byte
}
type FsEvent struct {
Unused [0]byte

View File

@@ -117,6 +117,10 @@ type GetNameInfo struct {
Unused [0]byte
}
type Shutdown struct {
Unused [0]byte
}
// ----------------------------------------------
/* Function type */
@@ -144,6 +148,7 @@ type ConnectionCb func(server *Stream, status c.Int)
// llgo:type C
type ShutdownCb func(req *Shutdown, status c.Int)
// ----------------------------------------------
/* Handle related function and method */