Skip to content

Remove impossible condition - #5119

Closed
drebelsky wants to merge 1 commit into
stellar:masterfrom
drebelsky:remove-impossible-cond
Closed

drebelsky wants to merge 1 commit into
stellar:masterfrom
drebelsky:remove-impossible-cond

Conversation

@drebelsky

Copy link
Copy Markdown
Contributor

Since prev is a shared_ptr that we don't update and we already know is non-null, this condition is impossible to hit.

Copilot AI review requested due to automatic review settings February 2, 2026 18:21

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR removes an unnecessary null check for a shared_ptr that is guaranteed to be non-null due to prior validation and capture semantics.

Changes:

  • Removed an impossible null check for prev in a lambda capture within DownloadApplyTxsWork::yieldMoreWork()

@drebelsky drebelsky mentioned this pull request Feb 23, 2026
@drebelsky

Copy link
Copy Markdown
Contributor Author

Since this is small, merging it into #5122.

@drebelsky drebelsky closed this Feb 23, 2026
github-merge-queue Bot pushed a commit that referenced this pull request Apr 8, 2026
* Add tracy binaries to `.gitignore`
* Add check for `SecretKey::random` in tests
* Remove duplicated header guard
* Don't run Soroban tests when Catch2 tests fail
* Remove outdated documentation (#4660 removed the "surveytopology"
endpoint)
* Remove impossible condition (#5119)
* Initialize `analyzeCriticalGroups` cli option
* Add clang-format rule for east const
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.

3 participants