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

Node: Replace usage of Variant with SumType #291

Merged
merged 2 commits into from
Jun 27, 2022

Conversation

Geod24
Copy link
Member

@Geod24 Geod24 commented Jun 22, 2022

Fixes #281

@codecov
Copy link

codecov bot commented Jun 22, 2022

Codecov Report

Merging #291 (912f6e4) into master (e157571) will decrease coverage by 0.59%.
The diff coverage is 50.00%.

❗ Current head 912f6e4 differs from pull request most recent head d0c691d. Consider uploading reports for the commit d0c691d to get more accurate results

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #291      +/-   ##
==========================================
- Coverage   96.03%   95.43%   -0.60%     
==========================================
  Files          28       28              
  Lines        4086     4100      +14     
==========================================
- Hits         3924     3913      -11     
- Misses        162      187      +25     
Impacted Files Coverage Δ
source/dyaml/node.d 91.13% <50.00%> (-2.61%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e157571...d0c691d. Read the comment docs.

@Geod24 Geod24 force-pushed the sumtype branch 3 times, most recently from 4e06a9a to cf1e82d Compare June 22, 2022 09:00
@Geod24
Copy link
Member Author

Geod24 commented Jun 22, 2022

Green

@Geod24
Copy link
Member Author

Geod24 commented Jun 22, 2022

It's a requirement to be able to support DIP1000

Copy link
Member

@Herringway Herringway left a comment

Choose a reason for hiding this comment

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

Seems good. Just a few things to address.

@Geod24
Copy link
Member Author

Geod24 commented Jun 24, 2022

@Herringway : Updated

@Geod24
Copy link
Member Author

Geod24 commented Jun 24, 2022

Except it doesn't work for LDC, and those error messages are really unhelpful.

@Herringway
Copy link
Member

it's pretty noisy, but I can see that LDC is deciding that the ubyte[] and SysTime lambdas in that tryMatch are @system for some reason

@Geod24
Copy link
Member Author

Geod24 commented Jun 27, 2022

@Herringway : The bug is related to inout. I will reduce it and report it upstream, but for now, can we go ahead with the present version ? It ensures that match itself is @safe if the delegates are.

@Herringway Herringway merged commit 335ed83 into dlang-community:master Jun 27, 2022
@Geod24 Geod24 deleted the sumtype branch June 28, 2022 08:40
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.

Use of std.sumtype.SumType instead of std.variant.Algebraic
2 participants