1 // Copyright 2022 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 //go:build goexperiment.arenas 6 7 package reflect 8 9 import "arena" 10 11 // ArenaNew returns a [Value] representing a pointer to a new zero value for the 12 // specified type, allocating storage for it in the provided arena. That is, 13 // the returned Value's Type is [PointerTo](typ). 14 func ArenaNew(a *arena.Arena, typ Type) Value { 15 return ValueOf(arena_New(a, PointerTo(typ))) 16 } 17 18 func arena_New(a *arena.Arena, typ any) any 19