DRAFT.md: `protocol` synopsis disagrees with the implementation on assignment, `noexcept` and the destructor

Đang mở
#508 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

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ó
2/5
Thời gian dự kiến
1-3 giờ
Mức phù hợp với người mới
52/100
Loại issue
Tài liệu
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
cpp
Lĩnh vực
documentation

Hướng nghiên cứu

Start with the protocol synopsis in DRAFT.md and compare it with the declarations in xyz/protocol.hh, using polymorphic in P3019 as the reference. Check the allocator-extended move constructor's noexcept specification, the missing copy and move assignment operators, and the destructor's constexpr status. Done means the synopsis matches the implementation on those three points, and OUTLINE.md is left unchanged.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Three places where the protocol synopsis in DRAFT.md matches neither xyz/protocol.hh nor P3019's polymorphic. OUTLINE.md already lists the default constructor, the narrowing constructors and the "identical constexpr" claim as R3 corrections. These are not on that list.

  1. The allocator-extended move constructor is unconditionally noexcept. With unequal allocators it allocates and move-constructs the owned object, so it can throw. The implementation and polymorphic use noexcept(allocator_traits<Allocator>::is_always_equal::value). #194 covers the semantics; the synopsis needs the matching exception specification. The allocator-extended narrowing move constructor has the same problem if narrowing stays (#88).
  2. There are no assignment operators. The synopsis declares neither copy nor move assignment. The implementation has both, generated conditionally like the constructors. Move assignment is noexcept when the allocator is always equal or propagates on move assignment, as in polymorphic.
  3. The destructor is not constexpr. The implementation's and polymorphic's are.
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

Mở trong Codespaces

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.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. 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.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của jbcoe/cc-protocol

Tất cả issue của jbcoe/cc-protocol

Issue tương tự

Thêm issue về C++

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.