Skip to content

Improve --bless output for tests/debuginfo - #164201

Merged
rust-bors[bot] merged 2 commits into
rust-lang:mainfrom
Walnut356:unsigned_unpack
Oct 12, 2026
Merged

rust-bors[bot] merged 2 commits into
rust-lang:mainfrom
Walnut356:unsigned_unpack

Conversation

@Walnut356

Copy link
Copy Markdown
Contributor

Fixes a few small things that came up while writing a new test.

The first commit fixes a small bug that caused unsigned integer values to be unpacked as signed values.

The second forces \n line endings, which makes running --bless less annoying on windows. Python defaults to platform specific line-endings by default. I think git normalizes away the differences anyway? But when working, they'd show up as changed files, so this just prevents those phantom diffs.

The bigger change in the second commit is sorting the types dictionary, which should help prevent diffs that are just shuffling types around. For reference, python (3.7+) dictionaries are in insertion order by default, so adding a new variable could sometimes cause a type to be processed sooner or later than it had been before.

All other list/dict instances are order-sensitive and/or changing their position has significance in the test, so those have remained the same.

r? @jieyouxu, @Kobzol

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Oct 12, 2026
@Kobzol

Kobzol commented Oct 12, 2026

Copy link
Copy Markdown
Member

Sorting the types by name makes sense. Thanks!

r? kobzol

@bors r+

@rust-bors

rust-bors Bot commented Oct 12, 2026

Copy link
Copy Markdown
Contributor

📌 Commit a2d2de0 has been approved by Kobzol

It is now in the queue for this repository.

@rustbot rustbot assigned Kobzol and unassigned jieyouxu Oct 12, 2026
@rust-bors rust-bors Bot added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Oct 12, 2026
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Oct 12, 2026
Improve `--bless` output for `tests/debuginfo`

Fixes a few small things that came up while writing a new test.

The first commit fixes a small bug that caused unsigned integer values to be unpacked as signed values.

The second forces `\n` line endings, which makes running `--bless` less annoying on windows. Python defaults to platform specific line-endings by default. I think git normalizes away the differences anyway? But when working, they'd show up as changed files, so this just prevents those phantom diffs.

The bigger change in the second commit is sorting the types dictionary, which should help prevent diffs that are just shuffling types around. For reference, python (3.7+) dictionaries are in insertion order by default, so adding a new variable could sometimes cause a type to be processed sooner or later than it had been before.

All other list/dict instances *are* order-sensitive and/or changing their position has significance in the test, so those have remained the same.

r? @jieyouxu, @Kobzol
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Oct 12, 2026
Improve `--bless` output for `tests/debuginfo`

Fixes a few small things that came up while writing a new test.

The first commit fixes a small bug that caused unsigned integer values to be unpacked as signed values.

The second forces `\n` line endings, which makes running `--bless` less annoying on windows. Python defaults to platform specific line-endings by default. I think git normalizes away the differences anyway? But when working, they'd show up as changed files, so this just prevents those phantom diffs.

The bigger change in the second commit is sorting the types dictionary, which should help prevent diffs that are just shuffling types around. For reference, python (3.7+) dictionaries are in insertion order by default, so adding a new variable could sometimes cause a type to be processed sooner or later than it had been before.

All other list/dict instances *are* order-sensitive and/or changing their position has significance in the test, so those have remained the same.

r? @jieyouxu, @Kobzol
rust-bors Bot pushed a commit that referenced this pull request Oct 12, 2026
…uwer

Rollup of 8 pull requests

Successful merges:

 - #164196 (`rust-analyzer` subtree update)
 - #164037 (Restrict application of optimization attributes from instance)
 - #164201 (Improve `--bless` output for `tests/debuginfo`)
 - #164202 ([rustdoc] Move the creation of `IndividualTestOptions` into the test runner closure to ensure the temporary folder is removed right after the test is done running)
 - #162140 (fn_addr_eq: we actually can guarantee basically nothing)
 - #163946 (Fix transmutability type mismatch bug)
 - #163978 (Copy over some methods from At to InferCtxt)
 - #164045 (-Zassumptions-on-binders: replace region vars with bound vars when handling alias outlives')
@rust-bors
rust-bors Bot merged commit 66e39ab into rust-lang:main Oct 12, 2026
14 checks passed
@rustbot rustbot added this to the 1.101.0 milestone Oct 12, 2026
rust-bors Bot pushed a commit that referenced this pull request Oct 12, 2026
Rollup merge of #164201 - Walnut356:unsigned_unpack, r=Kobzol

Improve `--bless` output for `tests/debuginfo`

Fixes a few small things that came up while writing a new test.

The first commit fixes a small bug that caused unsigned integer values to be unpacked as signed values.

The second forces `\n` line endings, which makes running `--bless` less annoying on windows. Python defaults to platform specific line-endings by default. I think git normalizes away the differences anyway? But when working, they'd show up as changed files, so this just prevents those phantom diffs.

The bigger change in the second commit is sorting the types dictionary, which should help prevent diffs that are just shuffling types around. For reference, python (3.7+) dictionaries are in insertion order by default, so adding a new variable could sometimes cause a type to be processed sooner or later than it had been before.

All other list/dict instances *are* order-sensitive and/or changing their position has significance in the test, so those have remained the same.

r? @jieyouxu, @Kobzol
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants