1// asmcheck 2 3// Copyright 2024 The Go Authors. All rights reserved. 4// Use of this source code is governed by a BSD-style 5// license that can be found in the LICENSE file. 6 7package p 8 9var x = func() int { 10 n := 0 11 f(&n) 12 return n 13}() 14 15func f(p *int) { 16 *p = 1 17} 18 19var y = 1 20 21// z can be static initialized. 22// 23// amd64:-"MOVQ" 24var z = y 25