goyield_unsafe.go raw

   1  // Copyright 2020 The gVisor Authors.
   2  //
   3  // Use of this source code is governed by a BSD-style
   4  // license that can be found in the LICENSE file.
   5  
   6  //go:build go1.14
   7  // +build go1.14
   8  
   9  // //go:linkname directives type-checked by checklinkname. Any other
  10  // non-linkname assumptions outside the Go 1 compatibility guarantee should
  11  // have an accompanied vet check or version guard build tag.
  12  
  13  package sync
  14  
  15  import (
  16  	_ "unsafe" // for go:linkname
  17  )
  18  
  19  //go:linkname goyield runtime.goyield
  20  func goyield()
  21