-
Notifications
You must be signed in to change notification settings - Fork 140
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
load
, copy
and borrow
cause a force cast
#1286
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1286 +/- ##
==========================================
- Coverage 77.43% 77.41% -0.02%
==========================================
Files 279 279
Lines 36159 36129 -30
==========================================
- Hits 27998 27969 -29
+ Misses 7069 7068 -1
Partials 1092 1092
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
Cadence Benchstat comparisonThis branch with compared with the base branch onflow:master commit 4fffc3b Results
|
Does this change merit a FLIP? On the one hand, it is a pretty small change design/implementation wise, and there is not much to discuss on those fronts. On the other hand, it has a pretty widespread affect on how people write code. I am curious whether or not this would benefit from going through the full FLIP process. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! 🎉
Yes, we should definitely pitch this to the community, then if there is interest, propose the breaking change through a FLIP and get agreement on it. Thank you for already creating a PR with the changes 👍 I could imagine putting this change behind a feature flag / option, then release it, disabled by default, in the emulator. |
The FLIP outlining this change has been approved and merged: onflow/flow#718 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, looks good! Just one comment regarding generating the error value, which requires the location range
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! Ready to get merged once the FLIP has been approved
Closes #1247
Description
This changes the storage API to cause
load
,copy
andborrow
to produce a runtime error if the supplied type argument does not match the stored value.master
branchFiles changed
in the Github PR explorer