aboutsummaryrefslogtreecommitdiffhomepage
path: root/ext/ext.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2026-03-17 14:09:38 +0900
committerOphestra <cat@gensokyo.uk>2026-03-17 14:09:38 +0900
commit1c2d5f6b57af2bb05759647d6e6ff1aa8ff47de0 (patch)
tree559d1f042e456b34e14ee6fb08d34b6f8f26089a /ext/ext.go
parentfaea1f4bd607263c59af8f228c97e9406ba482a7 (diff)
ext: integer limit values
For portably using C integers without cgo. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'ext/ext.go')
-rw-r--r--ext/ext.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/ext/ext.go b/ext/ext.go
index 12fd2550..2667f8e4 100644
--- a/ext/ext.go
+++ b/ext/ext.go
@@ -4,6 +4,7 @@ package ext
import (
"encoding/json"
"iter"
+ "math"
"strconv"
)
@@ -15,6 +16,12 @@ type (
Int = int32
)
+// Integer limit values.
+const (
+ MaxUint = math.MaxUint32
+ MaxInt = math.MaxInt32
+)
+
// SyscallNum represents an architecture-specific, Linux syscall number.
type SyscallNum Int