0xMiden / 0xMiden/miden-vm

Revisit code duplication between `Smt` and `LargeSmt`

Đang mở
#3,494 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
merkle
Ngôn ngữ chính
Rust
Star
772
Fork
352
Merge trung bình
1 ngày 7 giờ
Pull request đã merge (30 ngày)
84

Mô tả

There is overlap between `Smt` and `LargeSmt`. For example, `LargeSmt::build_subtrees_from_sorted_entries(...)` mirrors logic in the concurrent `Smt`.

We should revisit both implementations and reduce code duplication where possible to simplify maintenance and keep behavior consistent.

From PR 0xMiden/crypto#438 discussions [here](https://github.com/0xMiden/crypto/pull/438#discussion_r2320879897), [here](https://github.com/0xMiden/crypto/pull/438#discussion_r2320859090) and [here](https://github.com/0xMiden/crypto/pull/438#discussion_r2320834570).

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

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

Hướng nghiên cứu

Examine the `Smt` and `LargeSmt` structs and their `build_subtrees_from_sorted_entries` methods. Start by reading the linked PR discussions to understand the duplication context. Look for common logic that can be extracted into shared functions or traits. Determine what 'done' looks like by ensuring the refactored code passes existing tests and maintains consistent behavior.

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

Đánh giá

Công nghệ
rust
Lĩnh vực
backend
Loại issue
Tái cấu trúc
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
45/100

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.