You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
PR #1804 added support for valid Object::PadBUILD { ... } 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 BUILD in 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 BUILD declarations.
Keep valid Object::Pad BUILD blocks and their constructor behavior unchanged.
Activity
fglock commentedon Oct 26, 2026
Resolved by PR #1883, merged as 9ce6897. The PR adds malformed and out-of-class Object::Pad BUILD diagnostics with focused regression coverage.