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

add comments #23275

Merged
merged 1 commit into from
Feb 23, 2022
Merged

add comments #23275

merged 1 commit into from
Feb 23, 2022

Conversation

jeffwashington
Copy link
Contributor

Problem

Summary of Changes

Fixes #

@jeffwashington jeffwashington marked this pull request as ready for review February 22, 2022 16:31
Comment on lines 462 to 464
/// any entry at slot 'new_value.0' is replaced with 'new_value'.
/// or, 'new_value' is appended to the slot list if the slot did not exist previously.
/// returns true if caller should addref
Copy link
Contributor

Choose a reason for hiding this comment

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

Looks like this comment pertains the new version, found here:

/// Try to update an item in the slot list the given `slot` If an item for the slot
/// already exists in the list, remove the older item, add it to `reclaims`, and insert
/// the new item.
/// if 'other_slot' is some, then also remove any entries in the slot list that are at 'other_slot'
pub fn lock_and_update_slot_list(
current: &AccountMapEntryInner<T>,
new_value: (Slot, T),
other_slot: Option<Slot>,
reclaims: &mut SlotList<T>,
previous_slot_entry_was_cached: bool,
) {

But not this version of the fn. Dunno how you'd like to handle it for this PR though. Wdyt?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

fixed it

Copy link
Contributor

@brooksprumo brooksprumo left a comment

Choose a reason for hiding this comment

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

Love it!

@jeffwashington jeffwashington merged commit 2996f1f into solana-labs:master Feb 23, 2022
jeffwashington added a commit to jeffwashington/solana that referenced this pull request Mar 4, 2022
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.

2 participants