[chore]: Bump github.com/gin-contrib/cors from 1.5.0 to 1.7.0 (#2745)

This commit is contained in:
dependabot[bot]
2024-03-11 10:12:06 +00:00
committed by GitHub
parent 4c155aa847
commit e24efcac8b
158 changed files with 11727 additions and 4290 deletions

View File

@ -1,5 +1,4 @@
// +build !noasm !appengine
// Code generated by asm2asm, DO NOT EDIT·
// +build !noasm,amd64 !appengine,amd64
#include "go_asm.h"
#include "funcdata.h"

View File

@ -1,5 +1,4 @@
// +build !noasm !appengine
// Code generated by asm2asm, DO NOT EDIT.
// +build !noasm,!amd64 !appengine,!amd64
#include "go_asm.h"
#include "funcdata.h"

View File

@ -66,15 +66,16 @@ func FuncAddr(f interface{}) unsafe.Pointer {
}
}
//go:nocheckptr
func IndexChar(src string, index int) unsafe.Pointer {
return unsafe.Pointer(uintptr((*GoString)(unsafe.Pointer(&src)).Ptr) + uintptr(index))
}
//go:nocheckptr
func IndexByte(ptr []byte, index int) unsafe.Pointer {
return unsafe.Pointer(uintptr((*GoSlice)(unsafe.Pointer(&ptr)).Ptr) + uintptr(index))
}
//go:nosplit
func GuardSlice(buf *[]byte, n int) {
c := cap(*buf)
l := len(*buf)

View File

@ -211,3 +211,24 @@ func findReflectRtypeItab() *GoItab {
v := reflect.TypeOf(struct{}{})
return (*GoIface)(unsafe.Pointer(&v)).Itab
}
func AssertI2I2(t *GoType, i GoIface) (r GoIface) {
inter := IfaceType(t)
tab := i.Itab
if tab == nil {
return
}
if (*GoInterfaceType)(tab.it) != inter {
tab = Getitab(inter, tab.Vt, true)
if tab == nil {
return
}
}
r.Itab = tab
r.Value = i.Value
return
}
//go:noescape
//go:linkname Getitab runtime.getitab
func Getitab(inter *GoInterfaceType, typ *GoType, canfail bool) *GoItab

View File

@ -17,12 +17,12 @@
package rt
const (
MinInt48 = -(1 << 47)
MaxInt48 = +(1 << 47) - 1
MinInt48 int64 = -(1 << 47)
MaxInt48 int64 = +(1 << 47) - 1
)
func PackInt(v int) uint64 {
if u := uint64(v); v < MinInt48 || v > MaxInt48 {
if u := uint64(v); int64(v) < MinInt48 || int64(v) > MaxInt48 {
panic("int48 out of range")
} else {
return ((u >> 63) << 47) | (u & 0x00007fffffffffff)