reflect: fix Addr() indirect value/flags and add tests.

This commit is contained in:
Damian Gryski
2023-03-12 17:11:27 -07:00
committed by Ayke
parent 0e94553b26
commit a52cad3825
2 changed files with 26 additions and 1 deletions
+1 -1
View File
@@ -223,7 +223,7 @@ func (v Value) Addr() Value {
return Value{
typecode: pointerTo(v.typecode),
value: unsafe.Pointer(&v.value),
value: v.value,
flags: v.flags ^ valueFlagIndirect,
}
}