Skip to content

Commit 3999af5

Browse files
purego: clarify SyscallN usage (#300)
It was unclear how to properly use this function. Add some clarification. JupiterRider/purego-sdl3#4 (comment)
1 parent e9fe9ab commit 3999af5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

syscall.go

+3
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ type syscall15Args struct {
2727
// There is an internal maximum number of arguments that SyscallN can take. It panics
2828
// when the maximum is exceeded. It returns the result and the libc error code if there is one.
2929
//
30+
// In order to call this function properly make sure to follow all the rules specified in [unsafe.Pointer]
31+
// especially point 4.
32+
//
3033
// NOTE: SyscallN does not properly call functions that have both integer and float parameters.
3134
// See discussion comment https://github.com/ebiten/purego/pull/1#issuecomment-1128057607
3235
// for an explanation of why that is.

0 commit comments

Comments
 (0)