def byte_to_int(b):
 if (sys.version_info >= (3, 0)):
  return b
 return ord(b)

def byte_to_int ( b ) : if ( sys . version_info >= ( 3 , 0 ) ) : return b return ord ( b )
given an element in a binary buffer .