async def dump_uvarint(writer, n):
buffer = _UVARINT_BUFFER<EOL>if n == <NUM_LIT:0>:<EOL><INDENT>buffer[<NUM_LIT:0>] = <NUM_LIT:0><EOL>return await writer.awrite(buffer)<EOL><DEDENT>negative = n < <NUM_LIT:0><EOL>ll = -n if negative else n<EOL>size = <NUM_LIT:0><EOL>while ll != <NUM_LIT:0>:<EOL><INDENT>ll >>= <NUM_LIT:8><EOL>size += <NUM_LIT:1><EOL><DEDENT>buffer[<NUM_LIT:0>] = size<EOL>await writer.awrite(buffer)<EOL>ll = -n if negative else n<EOL>for _ in range(size):<EOL><INDENT>buffer[<NUM_LIT:0>] = ll & <NUM_LIT><EOL>await writer.awrite(buffer)<EOL>ll >>= <NUM_LIT:8><EOL><DEDENT>
Monero portable_binary_archive boost integer serialization
:param writer:
:param n:
:return: