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

[Core] Add LocalVector::has for convenience #91621

Merged
merged 1 commit into from
May 6, 2024

Conversation

AThousandShips
Copy link
Member

Not too many cases but useful for parity and clarity

Came across the discrepancy when working on:

@akien-mga akien-mga modified the milestones: 4.x, 4.3 May 6, 2024
@AThousandShips
Copy link
Member Author

Will open a godot-cpp PR as well

Copy link
Contributor

@smix8 smix8 left a comment

Choose a reason for hiding this comment

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

Yes please.

The navigation module NavMap also has a lot of uses of the LocalVector find() that you could likely replace if you feel like it.

@AThousandShips
Copy link
Member Author

AThousandShips commented May 6, 2024

Couldn't find any in there but will add any I find and squash

Edit: Found them, they used an unorthodox syntax

@AThousandShips AThousandShips requested a review from a team as a code owner May 6, 2024 16:12
@akien-mga akien-mga merged commit 7cdad33 into godotengine:master May 6, 2024
16 checks passed
@akien-mga
Copy link
Member

Thanks!

@rburing
Copy link
Member

rburing commented May 6, 2024

Shouldn't this have _FORCE_INLINE_?

@AThousandShips AThousandShips deleted the localvector_has branch May 6, 2024 20:56
@AThousandShips
Copy link
Member Author

It is missing from several short methods here, and should happen with any decent compiler, would be worth going over cases generally though here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants