-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Extend known for Go 1.23 compiler directives
- Loading branch information
1 parent
21d3bfd
commit 07893be
Showing
1 changed file
with
6 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -72,23 +72,23 @@ func isKnown(directive string) bool { | |
return false | ||
} | ||
|
||
// Found by running the following command on the source of go. | ||
// git grep -o -E -h '//go:[a-z_-]+' -- ':!**/*_test.go' ':!test/' ':!**/testdata/**' | sort -u | ||
// See https://pkg.go.dev/cmd/[email protected]#hdr-Compiler_Directives | ||
var known = []string{ | ||
// Found by running the following command on the source of go. | ||
// git grep -o -E -h '//go:[a-z_]+' -- ':!**/*_test.go' ':!test/' ':!**/testdata/**' | sort -u | ||
"binary", | ||
"binary-only-package", // https://pkg.go.dev/go/[email protected]#hdr-Binary_Only_Packages | ||
"build", | ||
"buildsomethingelse", | ||
"cgo_dynamic_linker", | ||
"cgo_export_dynamic", | ||
"cgo_export_static", | ||
"cgo_import_dynamic", | ||
"cgo_import_static", | ||
"cgo_ldflag", | ||
"cgo_unsafe_args", | ||
"debug", // https://go.dev/doc/godebug | ||
"embed", | ||
"generate", | ||
"linkname", | ||
"name", | ||
"nocheckptr", | ||
"noescape", | ||
"noinline", | ||
|
@@ -101,5 +101,6 @@ var known = []string{ | |
"systemstack", | ||
"uintptrescapes", | ||
"uintptrkeepalive", | ||
"wasmimport", | ||
"yeswritebarrierrec", | ||
} |