aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFelix Lange <fjl@twurst.com>2015-03-20 18:48:40 +0800
committerFelix Lange <fjl@twurst.com>2015-03-20 21:00:26 +0800
commitdcb9614dfec3c8dcaaa47e9fa516528fdc47279b (patch)
treedc34c5ff9fa8bd36051e26502a83e18d315a32ff
parentf7d1d601e92d3498f0fab5e80e5825d71f5d48fb (diff)
downloaddexon-dcb9614dfec3c8dcaaa47e9fa516528fdc47279b.tar
dexon-dcb9614dfec3c8dcaaa47e9fa516528fdc47279b.tar.gz
dexon-dcb9614dfec3c8dcaaa47e9fa516528fdc47279b.tar.bz2
dexon-dcb9614dfec3c8dcaaa47e9fa516528fdc47279b.tar.lz
dexon-dcb9614dfec3c8dcaaa47e9fa516528fdc47279b.tar.xz
dexon-dcb9614dfec3c8dcaaa47e9fa516528fdc47279b.tar.zst
dexon-dcb9614dfec3c8dcaaa47e9fa516528fdc47279b.zip
common: drop unused kind field from Value
This makes Value 24 bytes smaller on 64bit systems.
-rw-r--r--common/value.go6
1 files changed, 1 insertions, 5 deletions
diff --git a/common/value.go b/common/value.go
index f6150cb82..722e641b5 100644
--- a/common/value.go
+++ b/common/value.go
@@ -26,10 +26,7 @@ import (
// Value is useful whenever you feel that Go's types limit your
// ability to express yourself. In these situations, use Value and
// forget about this strong typing nonsense.
-type Value struct {
- Val interface{}
- kind reflect.Value
-}
+type Value struct{ Val interface{} }
func (val *Value) String() string {
return fmt.Sprintf("%x", val.Val)
@@ -53,7 +50,6 @@ func (val *Value) IsNil() bool {
}
func (val *Value) Len() int {
- //return val.kind.Len()
if data, ok := val.Val.([]interface{}); ok {
return len(data)
}