`collect_tokens_trailing_token` cleanups by nnethercote · Pull Request #127902 · rust-lang/rust
rustbot
added
S-waiting-on-review
labels
Jul 18, 2024
rustbot
added
S-waiting-on-author
and removed S-waiting-on-review
Status: Awaiting review from the assignee but also interested parties.labels
Jul 18, 2024
bors
added
S-waiting-on-bors
and removed S-waiting-on-author
Status: This is awaiting some action (such as code changes or more information) from the author.labels
Jul 18, 2024matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request
Jul 19, 2024…g_token-cleanups, r=petrochenkov `collect_tokens_trailing_token` cleanups More cleanups I made while understanding the code for processing `cfg_attr`, to fix test failures in rust-lang#124141. r? ``@petrochenkov``
bors
added
S-waiting-on-author
and removed S-waiting-on-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.labels
Jul 19, 2024The `Option`s within the `ReplaceRange`s within the hashmap are always `None`. This PR omits them and inserts them when they are extracted from the hashmap.
It's no shorter than `ret.attrs()`, and `ret.attrs()` is used multiple times earlier in the function.
This puts it just before the `replace_ranges` initialization, which makes sense because the two variables are closely related.
Currently in `collect_tokens_trailing_token`, `start_pos` and `end_pos` are 1-indexed by `replace_ranges` is 0-indexed, which is really confusing. Making them both 0-indexed makes debugging much easier.
bors
removed
the
S-waiting-on-author
label
Jul 19, 2024
bors
added
the
S-waiting-on-bors
label
Jul 19, 2024bors added a commit to rust-lang-ci/rust that referenced this pull request
Jul 19, 2024Rollup of 7 pull requests Successful merges: - rust-lang#121533 (Handle .init_array link_section specially on wasm) - rust-lang#127825 (Migrate `macos-fat-archive`, `manual-link` and `archive-duplicate-names` `run-make` tests to rmake) - rust-lang#127891 (Tweak suggestions when using incorrect type of enum literal) - rust-lang#127902 (`collect_tokens_trailing_token` cleanups) - rust-lang#127928 (Migrate `lto-smoke-c` and `link-path-order` `run-make` tests to rmake) - rust-lang#127935 (Change `binary_asm_labels` to only fire on x86 and x86_64) - rust-lang#127953 ([compiletest] Search *.a when getting dynamic libraries on AIX) r? `@ghost` `@rustbot` modify labels: rollup
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request
Jul 19, 2024Rollup merge of rust-lang#127902 - nnethercote:collect_tokens_trailing_token-cleanups, r=petrochenkov `collect_tokens_trailing_token` cleanups More cleanups I made while understanding the code for processing `cfg_attr`, to fix test failures in rust-lang#124141. r? `@petrochenkov`
nnethercote
deleted the
collect_tokens_trailing_token-cleanups
branch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters