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

Borrowed structs cleanup #5730

Merged
merged 2 commits into from
Oct 26, 2024
Merged

Conversation

robertbastian
Copy link
Member

No description provided.

@@ -108,16 +108,12 @@ impl LocaleFallbacker {
#[cfg(feature = "compiled_data")]
#[allow(clippy::new_ret_no_self)] // keeping constructors together
pub const fn new<'a>() -> LocaleFallbackerBorrowed<'a> {
Copy link
Member

Choose a reason for hiding this comment

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

Question: why aren't we just returning 'static?

Copy link
Member Author

Choose a reason for hiding this comment

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

Because the compiler cannot downcast this lifetime, and compiled data needed that somwhere.

@Manishearth Manishearth merged commit df81a5d into unicode-org:main Oct 26, 2024
28 checks passed
@robertbastian robertbastian deleted the borrowed branch October 27, 2024 12:43
robertbastian added a commit that referenced this pull request Oct 28, 2024
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