What version of Go are you using (go version)?
$ go version
go version go1.20 linux/amd64
What did you do?
This is the repro:
~/tmp/govet$ cat go.mod
module main
~/tmp/govet$ cat main.go
package main
// go:noescape
// go:nosplit
func procedure()
func main() {
procedure()
}
~/tmp/govet$ cat proc_amd64.s
#include "textflag.h"
#include "funcdata.h"
#include "go_asm.h"
TEXT ·procedure(SB), NOSPLIT|NOFRAME, $0-0
/*
Commented out garbage
MOVQ nonexistingprocedureargument+42(FP), ZMM1
*/
RET
# this compiles correctly
~/tmp/govet$ go build; echo $?
0
# vet complains
~/tmp/govet$ go vet -asmdecl
# main
./proc_amd64.s:9:1: [amd64] procedure: unknown variable nonexistingprocedureargument
When line 9 is commented with // then go vet does not complain.
What version of Go are you using (
go version)?What did you do?
This is the repro:
When line 9 is commented with
//thengo vetdoes not complain.