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

Backport cleos optional support #734

Merged
merged 8 commits into from
Aug 5, 2022
Merged

Conversation

ndcgundlach
Copy link
Contributor

Backport of changes to support nested optional.

Resolves: #778

@ndcgundlach ndcgundlach added the OCI OCI working this issue... label Jul 29, 2022
@ndcgundlach ndcgundlach self-assigned this Jul 29, 2022
@ndcgundlach ndcgundlach marked this pull request as ready for review August 1, 2022 14:01
@ClaytonCalabrese ClaytonCalabrese self-requested a review August 2, 2022 16:06
Copy link
Contributor

@ClaytonCalabrese ClaytonCalabrese left a comment

Choose a reason for hiding this comment

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

Just a whitespace change

Comment on lines 26 to 43
#define SETCONTAINERVAL(x) do { \
require_auth(user); \
psninfoindex2 tblIndex(get_self(), get_first_receiver().value); \
auto iter = tblIndex.find(user.value); \
if (iter == tblIndex.end()) \
{ \
tblIndex.emplace(user, [&](auto &row) { \
row.key = user; \
row.x = x; \
}); \
} \
else \
{ \
tblIndex.modify(iter, user, [&]( auto& row ) { \
row.x = x; \
}); \
} \
}while(0)
Copy link
Contributor

Choose a reason for hiding this comment

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

The spacing on this macro should be fixed up to fit our normal styling.

finally:
TestHelper.shutdown(cluster, walletMgr, testSuccessful, killEosInstances, killWallet)

exit(0)
Copy link
Member

Choose a reason for hiding this comment

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

I think this needs to check testSuccessful for the proper error code?

@spoonincode spoonincode dismissed their stale review August 3, 2022 17:04

I don't have time at the moment to do a full look over, but the one issue I mentioned before is fixed so dismissing the block

@ndcgundlach ndcgundlach merged commit e6c2c44 into main Aug 5, 2022
@ndcgundlach ndcgundlach deleted the backport_cleos_optional_support branch August 5, 2022 15:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCI OCI working this issue...
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Backport Cleos support for set<optional<T>> and vector<optional<T>>
3 participants