Make `cellog2` return `uint64` so that `CUSTODY_RESPONSE_DEPTH` has `uint64` type

This commit is contained in:
ericsson 2020-08-31 19:41:57 +03:00
parent 58fb58210f
commit 6df35fc3b5
1 changed files with 2 additions and 2 deletions

View File

@ -152,8 +152,8 @@ GeneralizedIndex = NewType('GeneralizedIndex', int)
SSZObject = TypeVar('SSZObject', bound=View) SSZObject = TypeVar('SSZObject', bound=View)
''' '''
SUNDRY_CONSTANTS_FUNCTIONS = ''' SUNDRY_CONSTANTS_FUNCTIONS = '''
def ceillog2(x: uint64) -> int: def ceillog2(x: uint64) -> uint64:
return (x - 1).bit_length() return uint64((x - 1).bit_length())
''' '''
PHASE0_SUNDRY_FUNCTIONS = ''' PHASE0_SUNDRY_FUNCTIONS = '''
def get_eth1_data(block: Eth1Block) -> Eth1Data: def get_eth1_data(block: Eth1Block) -> Eth1Data: