mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-11-02 04:42:26 -06:00
[chore]: Bump modernc.org/sqlite from 1.26.0 to 1.27.0 (#2339)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This commit is contained in:
parent
41435a6c4e
commit
28f85db30a
20 changed files with 526 additions and 143 deletions
20
vendor/modernc.org/libc/etc.go
generated
vendored
20
vendor/modernc.org/libc/etc.go
generated
vendored
|
|
@ -9,6 +9,7 @@ import (
|
|||
"io"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"reflect"
|
||||
"runtime"
|
||||
"runtime/debug"
|
||||
"sort"
|
||||
|
|
@ -436,7 +437,10 @@ func VaList(p uintptr, args ...interface{}) (r uintptr) {
|
|||
case uintptr:
|
||||
*(*uintptr)(unsafe.Pointer(p)) = x
|
||||
default:
|
||||
panic(todo("invalid VaList argument type: %T", x))
|
||||
sz := reflect.TypeOf(v).Size()
|
||||
copy(unsafe.Slice((*byte)(unsafe.Pointer(p)), sz), unsafe.Slice((*byte)(unsafe.Pointer((*[2]uintptr)(unsafe.Pointer(&v))[1])), sz))
|
||||
p += roundup(sz, 8)
|
||||
continue
|
||||
}
|
||||
p += 8
|
||||
}
|
||||
|
|
@ -459,6 +463,18 @@ func NewVaList(args ...interface{}) (va_list uintptr) {
|
|||
return VaList(NewVaListN(len(args)), args...)
|
||||
}
|
||||
|
||||
func VaOther(app *uintptr, sz uint64) (r uintptr) {
|
||||
ap := *(*uintptr)(unsafe.Pointer(app))
|
||||
if ap == 0 {
|
||||
return 0
|
||||
}
|
||||
|
||||
r = ap
|
||||
ap = roundup(ap+uintptr(sz), 8)
|
||||
*(*uintptr)(unsafe.Pointer(app)) = ap
|
||||
return r
|
||||
}
|
||||
|
||||
func VaInt32(app *uintptr) int32 {
|
||||
ap := *(*uintptr)(unsafe.Pointer(app))
|
||||
if ap == 0 {
|
||||
|
|
@ -584,6 +600,8 @@ func GoBytes(s uintptr, len int) []byte {
|
|||
return (*RawMem)(unsafe.Pointer(s))[:len:len]
|
||||
}
|
||||
|
||||
func Bool(v bool) bool { return v }
|
||||
|
||||
func Bool32(b bool) int32 {
|
||||
if b {
|
||||
return 1
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue