stackitem: simplify extracting value from map
Going through interfaces doesn't make it faster.
This commit is contained in:
parent
af8a4da6d9
commit
decff2bfb9
1 changed files with 1 additions and 1 deletions
|
@ -152,7 +152,7 @@ func (w *serContext) serialize(item Item) error {
|
||||||
case *Map:
|
case *Map:
|
||||||
w.seen[item] = sliceNoPointer{}
|
w.seen[item] = sliceNoPointer{}
|
||||||
|
|
||||||
elems := t.Value().([]MapElement)
|
elems := t.value
|
||||||
w.data = append(w.data, byte(MapT))
|
w.data = append(w.data, byte(MapT))
|
||||||
w.appendVarUint(uint64(len(elems)))
|
w.appendVarUint(uint64(len(elems)))
|
||||||
for i := range elems {
|
for i := range elems {
|
||||||
|
|
Loading…
Reference in a new issue