docs(classfile): add work surface type metadata#2701
docs(classfile): add work surface type metadata#2701aofei wants to merge 1 commit intogoplus:mainfrom
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #2701 +/- ##
=======================================
Coverage 94.12% 94.12%
=======================================
Files 32 32
Lines 10054 10054
=======================================
Hits 9463 9463
Misses 421 421
Partials 170 170 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Code Review
This pull request updates the classfile specification to introduce 'Work surface types' via a new -surface= flag and refines terminology throughout the document, such as standardizing on 'work file kind' and 'project classfile'. It also clarifies the resolution of symbols like base classes and prototype types within project groups. Review feedback suggests restoring the clarification regarding stripping leading asterisks from base-class names to avoid ambiguity and improving the phrasing of symbol resolution rules to better reflect the project group context.
There was a problem hiding this comment.
Pull request overview
Adds optional -surface=<ExportedName> metadata to class directives in the classfile specification, defining and constraining a “work surface type” for downstream semantic consumers, while also regularizing related terminology around project/work file kinds.
Changes:
- Extends
classdirective grammar to allow an optional-surface=flag and documents its validation rules. - Defines “work surface type” semantics, including the
*T implements Surfaceconformance requirement. - Updates terminology throughout the spec to consistently distinguish project/work classfiles and file kinds.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Well-structured specification PR. The new "Work surface types" section is thorough — especially the explicit negative-space enumeration of what the surface type does not affect. The glossary reorganization and terminology regularization ("work file kind," "work prototype type," etc.) are clear improvements. Main concerns: (1) "project base type" at line 180 should be "project base class" per the glossary, and the removed |
Define `work surface type` as optional classfile metadata for a work file kind and specify its validation and conformance rules. This also regularizes related terminology in `classfile-spec.md`, including `project file kind`, `work file kind`, and `work prototype type`, so the new metadata fits the existing classification and assembly rules. Updates goplus#2700 Signed-off-by: Aofei Sheng <aofei@aofeisheng.com>
Define
work surface typeas optional classfile metadata for a work file kind and specify its validation and conformance rules.This also regularizes related terminology in
classfile-spec.md, includingproject file kind,work file kind, andwork prototype type, so the new metadata fits the existing classification and assembly rules.Updates #2700