diff options
| author | _ov4 <ov4@ov4.org> | 2026-10-13 13:40:57 +0000 |
|---|---|---|
| committer | _ov4 <ov4@ov4.org> | 2026-10-13 13:40:57 +0000 |
| commit | f5a2541ed3faf9a942b867e2d54577352153afce (patch) | |
| tree | d5f737fdb8d77dc67d46cc12f8603c7df6a168c7 /include/cps/Parser.h | |
| parent | 5b08d59dba28b99cf991c02e837297fbfdb190c9 (diff) | |
Refactor record fields to preserve visibility and share parsing
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Diffstat (limited to 'include/cps/Parser.h')
| -rw-r--r-- | include/cps/Parser.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/cps/Parser.h b/include/cps/Parser.h index 49f418c..7344015 100644 --- a/include/cps/Parser.h +++ b/include/cps/Parser.h @@ -49,7 +49,9 @@ class Parser { bool ParseDesignatorSuffix(std::vector<DesignatorAccess> &Out); std::unique_ptr<StmtAST> ParseTypeDecl(); - bool ParseRecordField(std::vector<RecordFieldDecl> &Out); + std::optional<std::vector<RecordFieldDecl>> ParseRecordBody( + const std::string &Name, int Line, int EndToken); + bool ParseRecordField(std::vector<RecordFieldDecl> &Out, bool IsPublic); std::unique_ptr<StmtAST> ParseFunction(); std::unique_ptr<StmtAST> ParseProcedure(); |
