Skip to content
This repository has been archived by the owner on Jan 22, 2025. It is now read-only.

Expose executable and rent_epoch in AccountInfo #8619

Conversation

jackcmay
Copy link
Contributor

@jackcmay jackcmay commented Mar 4, 2020

Problem

AccountInfo does not expose the same members as Account, namely executable and rent_epoch.

One place this becomes an issue is when doing cross-program-invocations where the program's accounts are passed to another program from within the program.

Summary of Changes

Expose executable and rent_epoch in AccountInfo

Fixes #

@codecov
Copy link

codecov bot commented Mar 4, 2020

Codecov Report

❗ No coverage uploaded for pull request base (master@4f05f08). Click here to learn what that means.
The diff coverage is 25%.

@@           Coverage Diff            @@
##             master   #8619   +/-   ##
========================================
  Coverage          ?     80%           
========================================
  Files             ?     256           
  Lines             ?   55751           
  Branches          ?       0           
========================================
  Hits              ?   44610           
  Misses            ?   11141           
  Partials          ?       0

@@ -170,12 +170,14 @@ SOL_FN_PREFIX bool SolPubkey_same(const SolPubkey *one, const SolPubkey *two) {
*/
typedef struct {
SolPubkey *key; /** Public key of the account */
bool is_signer; /** Transaction was signed by this account's key? */
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@mvines Any opposition to this structure re-org, saves 8 bytes :-)

Copy link
Contributor

Choose a reason for hiding this comment

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

nope! We prolly ought to get this on 1.0.x for TdS

@jackcmay jackcmay added the v1.0 label Mar 4, 2020
@jackcmay jackcmay merged commit 25df95b into solana-labs:master Mar 4, 2020
@jackcmay jackcmay deleted the expose_executable-and-rent-epoch-in-account-info branch March 4, 2020 18:52
mergify bot pushed a commit that referenced this pull request Mar 4, 2020
solana-grimes added a commit that referenced this pull request Mar 4, 2020
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants