Skip to content

[Needs Verification] §1.5/§1.6 + Appendix A — reserved word/directive classification for at/on/inline/out #46

Description

@NickHodges

Sections: §1.5 Reserved Words, §1.6 Directive Words, Appendix A.1/A.2

Current text:
§1.5's reserved-word list includes at and on, and excludes out and inline (placed instead in §1.6's directive list). Appendix A mirrors this classification.

Problem:
This inverts the standard Embarcadero classification. out and inline are true reserved words (cannot be used as identifiers at all, even outside their special syntactic role), while at and on are not classified as reserved words or directives in the official docs — they are plain identifiers usable anywhere except their specific contextual syntax (except...on, raise...at). Two independent review passes over different chapters flagged this same inconsistency independently.

Why this needs compiler verification rather than a direct fix:
This project verifies lexical claims against the actual Delphi compiler via fixture tests (see the existing tests/Fixtures lexical version fixtures and related commits). Before changing the classification, verify with fixtures such as:

  • var out: Integer; — expected to fail to compile if out is truly reserved
  • var inline: Integer; — expected to fail to compile if inline is truly reserved
  • var on, at: Integer; — expected to compile successfully if at/on are NOT reserved

Suggested fix (pending verification):
Move out and inline into the §1.5/Appendix A.1 reserved-word list; remove at/on from that list (reclassify as ordinary identifiers with special meaning only in fixed syntactic positions, or drop the "context-restricted reserved word" note entirely).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationneeds-compiler-verificationClaim needs verification against the real Delphi compiler before fixing

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions