File: purego.go

package info (click to toggle)
golang-github-tinylib-msgp 1.2.5-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 836 kB
  • sloc: makefile: 47
file content (16 lines) | stat: -rw-r--r-- 290 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
//go:build (purego && !unsafe) || appengine
// +build purego,!unsafe appengine

package msgp

// let's just assume appengine
// uses 64-bit hardware...
const smallint = false

func UnsafeString(b []byte) string {
	return string(b)
}

func UnsafeBytes(s string) []byte {
	return []byte(s)
}