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

chore: Define arithmetic methods via Guppy source instead of custom compilers #703

Merged
merged 2 commits into from
Dec 10, 2024

Conversation

mark-koch
Copy link
Collaborator

@mark-koch mark-koch commented Dec 10, 2024

Closes #464.

Removes the CoercingChecker following #702. Also refactors ReversingChecker to figure out the unreversed method by itself.

@mark-koch mark-koch requested a review from a team as a code owner December 10, 2024 13:14
@mark-koch mark-koch requested review from aborgna-q and removed request for a team December 10, 2024 13:14
Comment on lines +109 to +110
# TODO: Literals should check against `nat`
return nat(1) if self else nat(0)
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

See #704

@codecov-commenter
Copy link

Codecov Report

Attention: Patch coverage is 90.74074% with 10 lines in your changes missing coverage. Please review.

Project coverage is 92.60%. Comparing base (eca9dc6) to head (49b6095).

Files with missing lines Patch % Lines
guppylang/std/builtins.py 89.47% 10 Missing ⚠️
Additional details and impacted files
@@               Coverage Diff               @@
##           feat/coerce     #703      +/-   ##
===============================================
- Coverage        92.72%   92.60%   -0.13%     
===============================================
  Files               71       71              
  Lines             7921     7872      -49     
===============================================
- Hits              7345     7290      -55     
- Misses             576      582       +6     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Base automatically changed from feat/coerce to main December 10, 2024 13:51
Copy link
Collaborator

@aborgna-q aborgna-q left a comment

Choose a reason for hiding this comment

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

🔥

@mark-koch mark-koch added this pull request to the merge queue Dec 10, 2024
Merged via the queue into main with commit 2b23f9a Dec 10, 2024
3 checks passed
@mark-koch mark-koch deleted the chore/arith-source branch December 10, 2024 15:52
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.

Define custom compilers for arithmetic & quantum ops using guppy programs
3 participants