Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement Lexer and Parser #1

Open
3 of 6 tasks
darkyeg opened this issue Apr 8, 2023 · 0 comments · May be fixed by #2
Open
3 of 6 tasks

Implement Lexer and Parser #1

darkyeg opened this issue Apr 8, 2023 · 0 comments · May be fixed by #2
Labels
feature For feature requests or suggestions

Comments

@darkyeg
Copy link
Member

darkyeg commented Apr 8, 2023

We need to implement a lexer and parser for our Raccoon language. The lexer should be able to tokenize the input source code into a stream of tokens, while the parser should be able to parse the tokens into an abstract syntax tree (AST). These components are essential for implementing the rest of the compiler.

The lexer and parser should be implemented according to the language specification, which can be found in the docs/specs.md file. The lexer should be able to handle all of the language's keywords, operators, and symbols, as well as any user-defined identifiers or literals. The parser should be able to generate a valid AST from the token stream, with appropriate error handling for syntax errors.

This issue involves writing a significant amount of code, so we should break it down into smaller subtasks and create separate issues for each subtask. We should also provide documentation and tests for the lexer and parser, to ensure that they work correctly and efficiently.

Tasks:

  • Define the grammar of the language #3
  • Implement the lexer to tokenize the input source code
  • Implement the parser to generate an AST from the token stream
  • Implement error handling for syntax errors in the lexer and parser
  • Write unit tests for the lexer and parser
  • Write documentation for the lexer and parser, including usage instructions and examples
@darkyeg darkyeg added the feature For feature requests or suggestions label Apr 8, 2023
@darkyeg darkyeg linked a pull request Apr 8, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature For feature requests or suggestions
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant