Skip to content

Commit e9a1101

Browse files
authored
test: add an example for the netpoll package (#670)
Besides, delete all old build constraints.
1 parent 1de2082 commit e9a1101

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+181
-92
lines changed

acceptor_unix.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build darwin || dragonfly || freebsd || linux || netbsd || openbsd
16-
// +build darwin dragonfly freebsd linux netbsd openbsd
1716

1817
package gnet
1918

client_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
//go:build darwin || dragonfly || freebsd || linux || netbsd || openbsd || windows
2-
// +build darwin dragonfly freebsd linux netbsd openbsd windows
32

43
package gnet
54

client_unix.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build darwin || dragonfly || freebsd || linux || netbsd || openbsd
16-
// +build darwin dragonfly freebsd linux netbsd openbsd
1716

1817
package gnet
1918

conn_map.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build (darwin || dragonfly || freebsd || linux || netbsd || openbsd) && !gc_opt
16-
// +build darwin dragonfly freebsd linux netbsd openbsd
17-
// +build !gc_opt
1816

1917
package gnet
2018

conn_matrix.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build (darwin || dragonfly || freebsd || linux || netbsd || openbsd) && gc_opt
16-
// +build darwin dragonfly freebsd linux netbsd openbsd
17-
// +build gc_opt
1816

1917
package gnet
2018

conn_matrix_test.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
//go:build (darwin || dragonfly || freebsd || linux || netbsd || openbsd) && gc_opt
2-
// +build darwin dragonfly freebsd linux netbsd openbsd
3-
// +build gc_opt
42

53
package gnet
64

connection_bsd.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build darwin || dragonfly || freebsd || netbsd || openbsd
16-
// +build darwin dragonfly freebsd netbsd openbsd
1716

1817
package gnet
1918

connection_unix.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build darwin || dragonfly || freebsd || linux || netbsd || openbsd
16-
// +build darwin dragonfly freebsd linux netbsd openbsd
1716

1817
package gnet
1918

engine_unix.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build darwin || dragonfly || freebsd || linux || netbsd || openbsd
16-
// +build darwin dragonfly freebsd linux netbsd openbsd
1716

1817
package gnet
1918

eventloop_unix.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build darwin || dragonfly || freebsd || linux || netbsd || openbsd
16-
// +build darwin dragonfly freebsd linux netbsd openbsd
1716

1817
package gnet
1918

eventloop_unix_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
//go:build darwin || dragonfly || freebsd || linux || netbsd || openbsd
2-
// +build darwin dragonfly freebsd linux netbsd openbsd
32

43
package gnet
54

listener_unix.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build darwin || dragonfly || freebsd || linux || netbsd || openbsd
16-
// +build darwin dragonfly freebsd linux netbsd openbsd
1716

1817
package gnet
1918

os_unix_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
//go:build darwin || dragonfly || freebsd || linux || netbsd || openbsd
2-
// +build darwin dragonfly freebsd linux netbsd openbsd
32

43
package gnet
54

os_windows_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
//go:build windows
2-
// +build windows
32

43
package gnet
54

pkg/io/io_bsd.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build darwin || dragonfly || freebsd || netbsd || openbsd
16-
// +build darwin dragonfly freebsd netbsd openbsd
1716

1817
package io
1918

pkg/netpoll/defs_bsd_32bit.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build (darwin || dragonfly || freebsd || netbsd || openbsd) && (386 || arm || mips || mipsle)
16-
// +build darwin dragonfly freebsd netbsd openbsd
17-
// +build 386 arm mips mipsle
1816

1917
package netpoll
2018

pkg/netpoll/defs_bsd_64bit.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build (darwin || dragonfly || freebsd || netbsd || openbsd) && (amd64 || arm64 || ppc64 || ppc64le || mips64 || mips64le || riscv64)
16-
// +build darwin dragonfly freebsd netbsd openbsd
17-
// +build amd64 arm64 ppc64 ppc64le mips64 mips64le riscv64
1816

1917
package netpoll
2018

pkg/netpoll/defs_linux.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build !poll_opt
16-
// +build !poll_opt
1716

1817
package netpoll
1918

pkg/netpoll/defs_linux_386.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
// cgo -cdefs defs2_linux.go
33

44
//go:build poll_opt
5-
// +build poll_opt
65

76
package netpoll
87

pkg/netpoll/defs_linux_amd64.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
// cgo -cdefs defs_linux.go defs1_linux.go
33

44
//go:build poll_opt
5-
// +build poll_opt
65

76
package netpoll
87

pkg/netpoll/defs_linux_arm.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
// license that can be found in the LICENSE file.
44

55
//go:build poll_opt
6-
// +build poll_opt
76

87
package netpoll
98

pkg/netpoll/defs_linux_arm64.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
// ../cmd/cgo/cgo -cdefs defs_linux.go defs1_linux.go defs2_linux.go
33

44
//go:build poll_opt
5-
// +build poll_opt
65

76
package netpoll
87

pkg/netpoll/defs_linux_mips64x.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@
33
// license that can be found in the LICENSE file.
44

55
//go:build (mips64 || mips64le) && linux && poll_opt
6-
// +build mips64 mips64le
7-
// +build linux
8-
// +build poll_opt
96

107
package netpoll
118

pkg/netpoll/defs_linux_mipsx.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@
33
// license that can be found in the LICENSE file.
44

55
//go:build (mips || mipsle) && linux && poll_opt
6-
// +build mips mipsle
7-
// +build linux
8-
// +build poll_opt
96

107
package netpoll
118

pkg/netpoll/defs_linux_ppc64.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
// cgo -cdefs defs_linux.go defs3_linux.go
33

44
//go:build poll_opt
5-
// +build poll_opt
65

76
package netpoll
87

pkg/netpoll/defs_linux_ppc64le.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
// cgo -cdefs defs_linux.go defs3_linux.go
33

44
//go:build poll_opt
5-
// +build poll_opt
65

76
package netpoll
87

pkg/netpoll/defs_linux_riscv64.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
// go tool cgo -godefs defs_linux.go defs1_linux.go defs2_linux.go
44

55
//go:build poll_opt
6-
// +build poll_opt
76

87
package netpoll
98

pkg/netpoll/defs_linux_s390x.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
// license that can be found in the LICENSE file.
44

55
//go:build poll_opt
6-
// +build poll_opt
76

87
package netpoll
98

pkg/netpoll/defs_poller.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build darwin || dragonfly || freebsd || linux || netbsd || openbsd
16-
// +build darwin dragonfly freebsd linux netbsd openbsd
1716

1817
package netpoll
1918

pkg/netpoll/defs_poller_bsd.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build darwin || dragonfly || freebsd || openbsd
16-
// +build darwin dragonfly freebsd openbsd
1716

1817
package netpoll
1918

pkg/netpoll/defs_poller_epoll.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build linux
16-
// +build linux
1716

1817
package netpoll
1918

pkg/netpoll/defs_poller_kqueue.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
//go:build darwin || dragonfly || freebsd || netbsd || openbsd
16-
// +build darwin dragonfly freebsd netbsd openbsd
1716

1817
package netpoll
1918

0 commit comments

Comments
 (0)