-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Some Symbol
related improvements
#74357
Some Symbol
related improvements
#74357
Conversation
r=me with documentation nit resolved. |
621cc66
to
b24bcc8
Compare
@bors r=oli-obk, rollup=iffy Iffy because it's fairly large. |
📌 Commit b24bcc883ac9b61217c845c7d8baef8c2889ac4f has been approved by |
🌲 The tree is currently closed for pull requests below priority 5, this pull request will be tested once the tree is reopened |
I don't think this will have a perf effect, but let's check to be sure. @bors try @rust-timer queue |
🙅 Please do not |
Awaiting bors try build completion |
@bors r- |
@bors try |
⌛ Trying commit b24bcc883ac9b61217c845c7d8baef8c2889ac4f with merge 4d6f6e62bd34546e4c64b9684af62346c5de2858... |
☀️ Try build successful - checks-actions, checks-azure |
Queued 4d6f6e62bd34546e4c64b9684af62346c5de2858 with parent 7e11379, future comparison URL. |
Finished benchmarking try commit (4d6f6e62bd34546e4c64b9684af62346c5de2858): comparison url. |
perf looks clean with potential small improvements, just needs a rebase |
The `lifetimes` field is always empty. This commit removes it, and renames the type as `Bounds`.
It's equivalent to `Ident::from_str_and_span`. The commit also introduces some more static symbols so that `Ident::new` can be used in various places instead of `Ident::from_str_and_span`. The commit also changes `Path::path` from a `&str` to a `Symbol`, which then allows the lifetime annotation to be removed from `Ty`. Also, the use of `Symbol` in `Bounds` removes the need for its lifetime annotation.
It's intended only for very temporary use.
This replaces the need for the `description` and `details` symbols in `UnsafetyViolation`, which are static. As a result some `Symbol::as_str()` calls are no longer necessary, which is nice.
b24bcc8
to
a4ba181
Compare
I rebase. @bors r=oli-obk |
📌 Commit a4ba181 has been approved by |
🌲 The tree is currently closed for pull requests below priority 5, this pull request will be tested once the tree is reopened |
…ents, r=oli-obk Some `Symbol` related improvements These commits make things nicer and avoid some `Symbol::as_str()` calls. r? @oli-obk
…ents, r=oli-obk Some `Symbol` related improvements These commits make things nicer and avoid some `Symbol::as_str()` calls. r? @oli-obk
…ents, r=oli-obk Some `Symbol` related improvements These commits make things nicer and avoid some `Symbol::as_str()` calls. r? @oli-obk
…ents, r=oli-obk Some `Symbol` related improvements These commits make things nicer and avoid some `Symbol::as_str()` calls. r? @oli-obk
…arth Rollup of 8 pull requests Successful merges: - rust-lang#73101 (Resolve items for cross-crate imports relative to the original module) - rust-lang#73269 (Enable some timeouts in SGX platform) - rust-lang#74033 (Add build support for Cargo's build-std feature.) - rust-lang#74351 (Do not render unstable items for rustc doc) - rust-lang#74357 (Some `Symbol` related improvements) - rust-lang#74371 (Improve ayu rustdoc theme) - rust-lang#74386 (Add RISC-V GNU/Linux to src/tools/build-manifest as a host platform) - rust-lang#74398 (Clean up E0723 explanation) Failed merges: r? @ghost
These commits make things nicer and avoid some
Symbol::as_str()
calls.r? @oli-obk