Conversation
links to correct relative path.
SoundBlaster
left a comment
There was a problem hiding this comment.
I think, this BNF specification describes the current ANTLR4 Lexer and Parser, and it complies with the Hypercode RFC.
|
@copilot review this PR please |
|
@SoundBlaster I've opened a new pull request, #6, to work on those changes. Once the pull request is ready, I'll request review from you. |
Hypercode Syntax Specification
There was a problem hiding this comment.
Pull request overview
This PR adds a formal Hypercode Syntax Specification document and updates references to point to the new specification file.
- Introduces a BNF/EBNF grammar specification for Hypercode
.hcfiles - Updates relative path references in RFC/Hypercode.md to correctly point to the new specification location
- Includes comprehensive examples, test cases, and AST visualization
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| RFC/Hypercode.md | Updated two relative path references from incorrect paths to ../EBNF/Hypercode_Syntax.md |
| EBNF/Hypercode_Syntax.md | New syntax specification document defining the formal grammar, with examples and test cases |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| <command> ::= <identifier> [<class>] [<id>] | ||
| <class> ::= "." <identifier> | ||
| <id> ::= "#" <identifier> | ||
| <block> ::= <indent-block> { <command-line> } |
There was a problem hiding this comment.
The definition of <block> is recursive but unclear. It references <indent-block> followed by { <command-line> }, but <command-line> already includes its own <indent> (line 23). This creates ambiguity about how indentation levels increase. Consider redefining to make the nested indentation relationship explicit, such as: <block> ::= { <command-line> } where the indentation level is implicitly deeper than the parent.
There was a problem hiding this comment.
I need to run and check this suggestion locally before I can approve it.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Fixes #2