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

compiler/parser: implement parser for bakugo's first spec #5

Merged
merged 48 commits into from
Nov 12, 2023

Conversation

ishwar00
Copy link
Owner

@ishwar00 ishwar00 commented Apr 21, 2023

Overview

This PR intends to implement the first spec of Bakugo.

Features

Parse spec of

  • Source code representation
  • Lexical elements
  • Constants
  • Variable
  • Types
  • Blocks
  • Declaration and scope
  • Expressions
  • Statements

@ishwar00 ishwar00 self-assigned this Apr 21, 2023
@ishwar00
Copy link
Owner Author

ishwar00 commented Apr 29, 2023

@Samyak2 parsing rune literals fixed here 45a1c67

@ishwar00 ishwar00 force-pushed the feat/add-parser-for-spec-one branch from 6447176 to 45a1c67 Compare April 30, 2023 03:15
ishwar00 and others added 14 commits April 30, 2023 09:21
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
@ishwar00 ishwar00 force-pushed the feat/add-parser-for-spec-one branch from a1c3196 to c244f4a Compare July 23, 2023 16:48
remove one test case because it is listing in `unreferenced snapshots`
even after accepting that snapshot, not sure why.
@ishwar00 ishwar00 force-pushed the feat/add-parser-for-spec-one branch from c244f4a to f9683cf Compare July 23, 2023 16:52
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
@ishwar00 ishwar00 force-pushed the feat/add-parser-for-spec-one branch from 59be536 to 8be3351 Compare July 30, 2023 08:24
@Samyak2 Samyak2 force-pushed the feat/add-parser-for-spec-one branch from 39421fc to a48ad18 Compare August 19, 2023 11:24
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
@Samyak2 Samyak2 force-pushed the feat/add-parser-for-spec-one branch from a48ad18 to 1f5e2e5 Compare August 19, 2023 11:25
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
@ishwar00 ishwar00 force-pushed the feat/add-parser-for-spec-one branch from 8b12520 to be7cef4 Compare September 17, 2023 13:37
ishwar00 and others added 9 commits September 24, 2023 23:24
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
also added one parser only error
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
@Samyak2
Copy link
Collaborator

Samyak2 commented Nov 4, 2023

  • top level var, const, types decl - no ast yet
  • return stmt with value - no ast yet
  • var, const, types decl - no ast yet
  • incdec stmt
  • assignment stmt
  • if else stmt
  • floats

Tests:

  • function decl - some tests already exist
  • signature - only types, ident list + type, ident + type. optional result.
  • expression - some tests already exist
  • operand - literal, name, fn call, arbitrary expr in ()/altering precedence
  • fn call - name f(), expression (f())(), literal as fn
  • arguments - only expression, type and exprs
  • unary ops, binary ops
  • tuple

Samyak2 and others added 10 commits November 4, 2023 20:41
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
Co-authored-by: Samyak S Sarnayak <samyak201@gmail.com>
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
Co-authored-by: ishwar00 <ishwargowda100@gmail.com>
Copy link
Collaborator

@Samyak2 Samyak2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's go

@Samyak2 Samyak2 marked this pull request as ready for review November 12, 2023 13:04
@Samyak2 Samyak2 merged commit 8874ea2 into main Nov 12, 2023
1 check passed
@Samyak2 Samyak2 deleted the feat/add-parser-for-spec-one branch November 12, 2023 13:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants