feat: speed up marshall align (#137)
This commit is contained in:
@@ -31,7 +31,8 @@ class Marshaller:
|
|||||||
offset = n - len(self._buf) % n
|
offset = n - len(self._buf) % n
|
||||||
if offset == 0 or offset == n:
|
if offset == 0 or offset == n:
|
||||||
return 0
|
return 0
|
||||||
self._buf.extend(bytes(offset))
|
for _ in range(offset):
|
||||||
|
self._buf.append(0)
|
||||||
return offset
|
return offset
|
||||||
|
|
||||||
def write_boolean(self, boolean: bool, type_: SignatureType) -> int:
|
def write_boolean(self, boolean: bool, type_: SignatureType) -> int:
|
||||||
|
|||||||
Reference in New Issue
Block a user