Skip to content

Use a specialized string interner to reduce the need for owned strings - #6356

Closed
dotdash wants to merge 1 commit into
rust-lang:incomingfrom
dotdash:strinterner
Closed

Use a specialized string interner to reduce the need for owned strings#6356
dotdash wants to merge 1 commit into
rust-lang:incomingfrom
dotdash:strinterner

Conversation

@dotdash

Copy link
Copy Markdown
Contributor

&str can be turned into @~str on demand, using to_owned(), so for
strings, we can create a specialized interner that accepts &str for
intern() and find() but stores and returns @~str.

&str can be turned into @~str on demand, using to_owned(), so for
strings, we can create a specialized interner that accepts &str for
intern() and find() but stores and returns @~str.
@brson

Copy link
Copy Markdown
Contributor

Good riddance to allocated strings! 🌵

bors added a commit that referenced this pull request May 10, 2013
&str can be turned into @~str on demand, using to_owned(), so for
strings, we can create a specialized interner that accepts &str for
intern() and find() but stores and returns @~str.
@borsbors closed this May 10, 2013
flip1995 pushed a commit to flip1995/rust that referenced this pull request Jun 4, 2022
…endoo
Don't lint `useless_transmute` on types with erased regions
fixesrust-lang#6356fixesrust-lang#3340fixesrust-lang#2906
This should get a proper fix at some point, but this at least gets the lint running on some types.
cc rust-lang#5343
changelog: Don't lint `useless_transmute` on types with erased regions
U007D pushed a commit to U007D/rust-mos that referenced this pull request Aug 21, 2026
Signed-off-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
U007D pushed a commit to U007D/rust-mos that referenced this pull request Aug 21, 2026
Signed-off-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
U007D pushed a commit to U007D/rust-mos that referenced this pull request Aug 21, 2026
6384: add doctest runnables on struct r=lnicola a=bnjjj
I will check for how to do the same on trait implementation on another PR.
rust-lang#6356
Co-authored-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
U007D pushed a commit to U007D/rust-mos that referenced this pull request Aug 21, 2026
8952: add support of impl block for doctest into runnables r=matklad a=bnjjj
closerust-lang#6356 Co-authored-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
Sign up for freeto 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.

4 participants

@dotdash@brson@pcwalton@bors