Comparison between two protocol objects
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 25/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Cần làm rõ
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- cpp
- Lĩnh vực
- backend-api-design
Hướng nghiên cứu
The issue names no files or tests. Start by reading #439 and #208, then trace the protocol and protocol_view comparison design described here; done means the open semantic, type-identity, mismatch, valueless, conversion, and scope questions have a decided specification.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
#439 forwards member comparisons with an operand of another type and rejects any comparison on an interface I with an operand of type I. The idiomatic declaration is therefore free to be given a meaning:
struct I {
bool operator==(const I&) const = default;
auto operator<=>(const I&) const = default;
};
protocol<I> p(A{}), q(B{});
p == q;
Open questions:
- Meaning. Does
const I&stand for the conforming type itself? Conformance would then meanChasoperator==(const C&) const, andprotocol<I>would getoperator==(const protocol&) const. Should that apply only to defaulted comparisons, or to user-declared ones as well? - Type identity. The thunk must know that both operands hold the same
Cbefore it casts.typeidneeds RTTI. The vtable address is cheap but not reliably unique across shared libraries. - Mismatched types.
==can returnfalse.<=>could returnpartial_ordering::unordered(which rules outstrong_orderingon the interface), order bytype_index(an unspecified order), or throw as Boost.TypeErasure does.std::polymorphicomits comparison for this reason. - Valueless operands. See #208.
protocol_view. Does it compare the referenced objects or the pointers? Should mixedprotocol/protocol_viewcomparison be allowed?- Conversions between interfaces. What does a comparison that names the conforming type do when a protocol converts to another interface?
- Scope. Does "own type" stop at comparisons, or extend to members such as
void merge(const I&)andI clone() const?
An alternative is a library opt-in (a tag base or trait) in place of rewriting const I&. That works against the design's premise that the interface struct is the whole specification.
- Ngôn ngữ chính
- C++
- Star
- 12
- Fork
- 4
- Merge trung bình
- 1 ngày 11 giờ
- Pull request đã merge (30 ngày)
- 15
Chuẩn bị môi trường
Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của jbcoe/cc-protocol
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
jbcoe/cc-protocol#507 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
jbcoe/cc-protocol#455 · 3 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
jbcoe/cc-protocol#407 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
jbcoe/cc-protocol#194 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 15/100
jbcoe/cc-protocol#513 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của jbcoe/cc-protocol
Issue tương tự
-
Tests: parallel pyinstallcheck runs oversubscribe the machine through nested TBB and BLAS poolsCó thể đã có người làm Có pull request liên kết đang mở hoặc đã được merge. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Maintainer thường phản hồi trong vòng 1 ngày
-
CefRequestContext::ClearHttpCache crashes with a null callback, though the callback is optionalĐang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
chromiumembedded/cef#4376 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
itinance/react-native-fs#1270 ·
-
area-CodeGen-coreclr untriaged
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
dotnet/runtime#138181 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
yuaotian/antigravity-proxy#181 ·