mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-05 11:37:46 +00:00
12 lines
192 B
Go
12 lines
192 B
Go
package runtime
|
|
|
|
//go:linkname indexBytePortable internal/bytealg.IndexByte
|
|
func indexBytePortable(s []byte, c byte) int {
|
|
for i, b := range s {
|
|
if b == c {
|
|
return i
|
|
}
|
|
}
|
|
return -1
|
|
}
|