Source file src/cmd/link/testdata/linkname/systemstack.go
1 // Copyright 2026 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 // Linkname systemstack is not allowed, even if it is 6 // defined in assembly. 7 8 package main 9 10 import _ "unsafe" 11 12 func f() {} 13 14 func main() { 15 systemstack(f) 16 } 17 18 //go:linkname systemstack runtime.systemstack 19 func systemstack(func()) 20