From 66b77acb1c8b86f0be3836ccaf31683c0bfa317a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 27 Nov 2023 13:15:03 +0000 Subject: [chore]: Bump github.com/gin-contrib/cors from 1.4.0 to 1.5.0 (#2388) Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- vendor/github.com/bytedance/sonic/internal/rt/fastmem.go | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'vendor/github.com/bytedance/sonic/internal/rt') diff --git a/vendor/github.com/bytedance/sonic/internal/rt/fastmem.go b/vendor/github.com/bytedance/sonic/internal/rt/fastmem.go index 5bf80dd4e..e3bf0db91 100644 --- a/vendor/github.com/bytedance/sonic/internal/rt/fastmem.go +++ b/vendor/github.com/bytedance/sonic/internal/rt/fastmem.go @@ -109,4 +109,16 @@ func StrFrom(p unsafe.Pointer, n int64) (s string) { (*GoString)(unsafe.Pointer(&s)).Ptr = p (*GoString)(unsafe.Pointer(&s)).Len = int(n) return +} + +// NoEscape hides a pointer from escape analysis. NoEscape is +// the identity function but escape analysis doesn't think the +// output depends on the input. NoEscape is inlined and currently +// compiles down to zero instructions. +// USE CAREFULLY! +//go:nosplit +//goland:noinspection GoVetUnsafePointer +func NoEscape(p unsafe.Pointer) unsafe.Pointer { + x := uintptr(p) + return unsafe.Pointer(x ^ 0) } \ No newline at end of file -- cgit v1.3