瀏覽代碼

Remove unnecessary bit operation.

main
Cheng Chang 5 年之前
父節點
當前提交
cf1b5f4732
共有 1 個檔案被更改,包括 1 行新增1 行删除
  1. +1
    -1
      util/coding.cc

+ 1
- 1
util/coding.cc 查看文件

@ -82,7 +82,7 @@ char* EncodeVarint64(char* dst, uint64_t v) {
static const int B = 128;
unsigned char* ptr = reinterpret_cast<unsigned char*>(dst);
while (v >= B) {
*(ptr++) = (v & (B-1)) | B;
*(ptr++) = v | B;
v >>= 7;
}
*(ptr++) = static_cast<unsigned char>(v);

Loading…
取消
儲存