Kotlin printer: streams as collection operations
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 55/100
Hướng nghiên cứu
Start in the Kotlin printer code that translates Java stream expression chains, and run the existing printer tests to observe the current output. Implement the stage, terminal, laziness, and unsupported-operation mappings listed in the issue. Done means supported Collection.stream() chains become Kotlin collection operations, while unsupported cases such as findFirst, count, limit, and flatMap remain streams.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Split off from #231. Java translated to Kotlin keeps its streams: names.stream().filter(…).map(…).collect(Collectors.toList()) (.stream() 40 / 77 / 30 times in the langchain4j / fernflower / guava output). Kotlin's collections have these operations themselves.
First pass, a chain from Collection.stream():
- stages
filter,map,distinct,sorted()(Comparable elements),sorted(c)→sortedWith(c);filter(Objects::nonNull)→filterNotNull() - terminals
collect(toList())/toList()→ nothing,toList()ortoMutableList()as the position takes it;collect(toSet())→toSet()/toMutableSet();collect(joining(…))→joinToString(…);anyMatch/allMatch/noneMatch→any/all/none;forEach - where Java's laziness can show (a short-circuiting terminal or
forEachafter a stage):asSequence()
Anything else stays a stream: findFirst (that is the Optional item of #231), count, mapToInt, limit, flatMap, custom collectors, Arrays.stream, Stream.of.
🤖 Generated with Claude Code
- Ngôn ngữ chính
- Java
- Star
- 1
- Fork
- 1
- Merge trung bình
- 48 phút
- Pull request đã merge (30 ngày)
- 2
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- 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 CodeLaser/maddi
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
-
Javadoc warnings are the only noise on an otherwise clean CI runCó thể làm lại được @jayeshamundkar06-bit đã nhận 27 ngày trước và không có pull request nào đang mở. Đang mởbuild/ci good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
-
enhancement
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 42/100
Tất cả issue của CodeLaser/maddi
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
federicoiosue/Omni-Notes#1044 ·
-
Industrial Center Text TypoĐang mởBug
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 68/100
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 82/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Terraform releases proxy leaves a temp folder behind on every cache refreshCó thể đã có người làm @dhananjay6561 đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
terrakube-io/terrakube#4069 · 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 85/100
find-sec-bugs/find-sec-bugs#789 ·