Skip to content

process_comment: Use last defined callback #3103

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

Merged
merged 1 commit into from
Feb 1, 2025

Conversation

jschwe
Copy link
Contributor

@jschwe jschwe commented Jan 30, 2025

Instead of using the last registered callback, iterate through all callbacks and use the last one that was actually implemented and returned Some().
This is essential when users register more than one parse callback.

Instead of using the last registered callback,
iterate through all callbacks and use the last
one that was actually implemented and returned `Some()`.

This is essentially when users register more than one parse callback -
the process_comment may not be the last.
Copy link
Contributor

@emilio emilio left a comment

Choose a reason for hiding this comment

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

Thanks!

@emilio emilio added this pull request to the merge queue Feb 1, 2025
Merged via the queue into rust-lang:main with commit 14ee85b Feb 1, 2025
34 checks passed
@jschwe jschwe deleted the jschwender/process_comment branch February 1, 2025 20:33
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