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

[Refactor] Use the Consumer pattern for code generation. #2282

Open
wants to merge 24 commits into
base: testnet3
Choose a base branch
from

Conversation

d0cd
Copy link
Collaborator

@d0cd d0cd commented Feb 26, 2023

This PR,

  • Removes AssociatedConstants from the AST
  • Refactors the Visitor, Reconstructor, and Consumer traits.
  • Refactors the code generation pass to use the Consumer.

@d0cd d0cd changed the title [Refactor] Use the Consumer trait for code generation. [Refactor] Use the Consumer pattern for code generation. Feb 26, 2023
@codecov
Copy link

codecov bot commented Feb 26, 2023

Codecov Report

Merging #2282 (3532dcb) into testnet3 (c8f6089) will increase coverage by 0.12%.
The diff coverage is 78.70%.

@@             Coverage Diff              @@
##           testnet3    #2282      +/-   ##
============================================
+ Coverage     77.94%   78.06%   +0.12%     
============================================
  Files           150      148       -2     
  Lines          4571     4619      +48     
  Branches       4569     4617      +48     
============================================
+ Hits           3563     3606      +43     
- Misses         1008     1013       +5     
Impacted Files Coverage Δ
...c/expressions/access/associated_function_access.rs 50.00% <ø> (ø)
...mpiler/ast/src/expressions/access/member_access.rs 50.00% <ø> (ø)
compiler/ast/src/expressions/access/mod.rs 57.14% <ø> (ø)
...ompiler/ast/src/expressions/access/tuple_access.rs 100.00% <ø> (ø)
compiler/ast/src/expressions/mod.rs 50.00% <ø> (ø)
compiler/ast/src/lib.rs 78.37% <ø> (ø)
compiler/ast/src/passes/consumer.rs 89.28% <ø> (+0.39%) ⬆️
compiler/ast/src/passes/visitor.rs 87.50% <ø> (-0.74%) ⬇️
compiler/compiler/src/compiler.rs 86.66% <ø> (ø)
compiler/ast/src/passes/reconstructor.rs 67.66% <66.66%> (-1.00%) ⬇️
... and 25 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

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.

1 participant