-
Notifications
You must be signed in to change notification settings - Fork 443
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
Return LangError
s from constructors
#1504
Merged
Merged
Changes from all commits
Commits
Show all changes
32 commits
Select commit
Hold shift + click to select a range
536b500
Return `ConstructorResult` in `deploy()`
HCastano 1ab55d9
Wrap return type with `Result` in metadata
HCastano 79dff48
Check that constructor's return Results in tests
HCastano 228604c
Add test showing that `Result`s are decoded correctly
HCastano bb4c1a2
Correctly generate metadata for constructors
HCastano 15439a4
Merge branch 'master' into hc-impl-lang-error-for-constructors
HCastano 27b6b97
Fix some nitpicks from Andrew's PR
HCastano eb10da6
Wrap dispatch return types with `Ok`
HCastano 8b1aa66
Manually wrap metadata return with `ConstructorResult`
HCastano 36556e7
Fix existing constructor integration tests
HCastano e61576e
Remove constructor related test from `integration-flipper`
HCastano a3e0b24
Fix compile tests
HCastano fb8d293
Add `ident` to dictionary
HCastano 394ffca
Simplify code
athei 2f026a2
Driveby: Also simplify call dispatch
athei c501d84
Small fixes to type paths
HCastano c307516
Check that actual instantiate call fails
HCastano aaebac4
Add some tests using the `CreateBuilder`
HCastano b63ef91
Clean up the `create_builder` tests
HCastano 0c37262
Merge branch 'master' into hc-impl-lang-error-for-constructors
HCastano ec6253d
Remove unused method
HCastano d56b728
Format code for generating constructor return type
HCastano 053f570
Add `constructors-return-value` to CI
HCastano 7305887
Move shared imports out of messages
HCastano 0ef75f9
Appease Clippy
HCastano 4607a67
Appease Clippy
HCastano f791bfb
Try flipping order of tests
HCastano 5d0f164
Change message name
HCastano e8b4e75
Revert last two changes
HCastano cab6c98
Try moving message related test to different module
HCastano 4dc9973
Revert "Try moving message related test to different module"
HCastano ad1cab7
Try different type for account ID
HCastano File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -46,6 +46,7 @@ evaluable | |
fuzzer | ||
getter | ||
growable | ||
ident | ||
interoperate | ||
invariants | ||
kB | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Looking at this control flow again: from a readability perspective, I wonder whether it would be better to have this inside the
Ok
arm of the match. It seems unusual because of the semantics ofreturn_value
returning immediately!
. A casual reader might expect this statement to always be executed. Just a note for something to consider when we get to refactoring this dispatch logic.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.
Yeah that seems fair enough. I'll leave it for a follow-up since we'll want to change it for messages too