Report malformed Object::Pad BUILD declarations clearly
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ó
- 3/5
- Thời gian dự kiến
- Nửa ngày
- Mức phù hợp với người mới
- 45/100
Hướng nghiên cứu
Start with the class-block parser in the Perl front end, where BUILD is recognized and where a missing block body falls through into expression parsing. Reproduce with class BadBuild { BUILD method value {} } under use Object::Pad; and confirm the current unblessed-reference error. Done when that input yields a targeted syntax diagnostic, out-of-class BUILD gets coverage, and valid BUILD blocks still pass the existing Object::Pad tests.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Context
PR #1804 added support for valid Object::Pad BUILD { ... } blocks, including execution after field initialization, and passed the CAD::OpenSCAD 0.14 acceptance tests on both JVM and interpreter backends. The original parser failure is fixed.
Remaining diagnostic gap
Malformed or misplaced BUILD syntax should receive a focused compile-time diagnostic. Today, an incomplete class block can fall through into ordinary expression parsing and fail later with a confusing runtime error.
For example, against the merged implementation:
use Object::Pad;
class BadBuild { BUILD method value {} }
currently reports Can't call method "value" on unblessed reference instead of identifying the malformed BUILD declaration.
Follow-up
- Detect
BUILDin a class block when it is not followed by a block body and report a targeted syntax diagnostic. - Add project-owned coverage for malformed and out-of-class
BUILDdeclarations. - Keep valid Object::Pad
BUILDblocks and their constructor behavior unchanged.
Related: #1450, PR #1804.
- Ngôn ngữ chính
- Perl
- Star
- 64
- Fork
- 7
- Merge trung bình
- 5 giờ 25 phút
- Pull request đã merge (30 ngày)
- 213
Chuẩn bị môi trường
- Có Dockerfile hoặc 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 fglock/PerlOnJava
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
fglock/PerlOnJava#1651 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
fglock/PerlOnJava#1579 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:cpan-port area:unicode bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
fglock/PerlOnJava#1341 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:cpan-port area:runtime bug
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 28/100
fglock/PerlOnJava#1802 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:backend area:cpan-port area:runtime bug
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 30/100
fglock/PerlOnJava#1801 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của fglock/PerlOnJava
Issue tương tự
-
Add .gitattributes so share/skel keeps LF on a Windows git checkoutCó thể đã có người làm @sadhana-s-codez đã nhận 1 ngày trước. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 85/100
PerlDancer/Dancer2#1854 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
major/MySQLTuner-perl#1007 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 88/100
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 88/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 69/100
bioconda/bioconda-recipes#70187 ·
Maintainer thường phản hồi trong vòng 2 ngày