mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-24 05:36:46 +00:00
Update type.go
This commit is contained in:
parent
12067d66f9
commit
4cd9af3c3b
1 changed files with 4 additions and 8 deletions
|
|
@ -252,15 +252,11 @@ func (t Type) GetType() reflect.Type {
|
||||||
case FixedBytesTy:
|
case FixedBytesTy:
|
||||||
return reflect.ArrayOf(t.Size, reflect.TypeFor[byte]())
|
return reflect.ArrayOf(t.Size, reflect.TypeFor[byte]())
|
||||||
case BytesTy:
|
case BytesTy:
|
||||||
return reflect.SliceOf(reflect.TypeFor[byte]())
|
return reflect.TypeFor[[]byte]()
|
||||||
case HashTy:
|
case HashTy, FixedPointTy: // currently not used
|
||||||
// hashtype currently not used
|
return reflect.TypeFor[[32]byte]()
|
||||||
return reflect.ArrayOf(32, reflect.TypeFor[byte]())
|
|
||||||
case FixedPointTy:
|
|
||||||
// fixedpoint type currently not used
|
|
||||||
return reflect.ArrayOf(32, reflect.TypeFor[byte]())
|
|
||||||
case FunctionTy:
|
case FunctionTy:
|
||||||
return reflect.ArrayOf(24, reflect.TypeFor[byte]())
|
return reflect.TypeFor[[24]byte]()
|
||||||
default:
|
default:
|
||||||
panic("Invalid type")
|
panic("Invalid type")
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue