abseil / abseil/abseil-cpp

signed/unsigned compare in btree.h

Đang mở
#771 7 bình luận 1 reaction 0 người được giao Xem trên GitHub
bug
Ngôn ngữ chính
C++
Star
18.1k
Fork
3.2k
Merge trung bình
20 giờ 36 phút
Pull request đã merge (30 ngày)
1

Mô tả

**Describe the bug**

Since the enum containing kNodeValues was changed to be explicitly uint32_t, there is now a signed/unsigned comparison:

external/abseil/absl/container/internal/btree.h:2439:19: error: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Werror=sign-compare]
2439 | if (max_count < kNodeValues) {
| ~~~~~~~~~~^~~~~~~~~~~~~

**Steps to reproduce the bug**

Compile revision c6b3f2cf583d8fec124f9d70a172b513363506fe with sign comparison warnings turned on

**What version of Abseil are you using?**
HEAD (c6b3f2cf583d8fec124f9d70a172b513363506fe and later)

**What operating system and version are you using**
Linux (RHEL 6)

**What compiler and version are you using?**
gcc 9.1.0
clang 8.0.1
clang 9.0.0

**What build system are you using?**
cmake 3.15.0

**Additional context**

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.