Skip to content

Account for C string literals and format_args in HiddenUnicodeCodepoints lint #134956

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 3 commits into from
Dec 31, 2024

Conversation

compiler-errors
Copy link
Member

This is stacked on #134955, and either that can land first or both of them can land together here. I split this out because this is a bit more involved of an impl.

Fixes #94945

@rustbot
Copy link
Collaborator

rustbot commented Dec 31, 2024

r? @jieyouxu

rustbot has assigned @jieyouxu.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@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 Dec 31, 2024
@jieyouxu jieyouxu added A-lints Area: Lints (warnings about flaws in source code) such as unused_mut. L-text_direction_codepoint_in_literal Lint: text_direction_codepoint_in_literal labels Dec 31, 2024
Copy link
Member

@jieyouxu jieyouxu left a comment

Choose a reason for hiding this comment

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

Thanks!

fmt.0 = Symbol::intern(&format!("{}\n", fmt.0));
fmt.symbol = Symbol::intern(&format!("{}\n", fmt.symbol));
Copy link
Member

Choose a reason for hiding this comment

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

Remark: this is indeed easier to follow

@jieyouxu
Copy link
Member

Let's land both of them here in this PR.

@bors r+ rollup

@bors
Copy link
Collaborator

bors commented Dec 31, 2024

📌 Commit ea291e5 has been approved by jieyouxu

It is now in the queue for this repository.

@bors bors 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 Dec 31, 2024
@jieyouxu jieyouxu changed the title Account for format_args in HiddenUnicodeCodepoints lint Account for C string literals and format_args in HiddenUnicodeCodepoints lint Dec 31, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request Dec 31, 2024
…iaskrgr

Rollup of 4 pull requests

Successful merges:

 - rust-lang#134610 (Format `build.toml` consistently in platform support docs)
 - rust-lang#134918 (Windows: Enable issue 70093 link tests)
 - rust-lang#134953 (Fix doc for read&write unaligned in zst operation)
 - rust-lang#134956 (Account for C string literals and `format_args` in `HiddenUnicodeCodepoints` lint)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 0c94f63 into rust-lang:master Dec 31, 2024
6 checks passed
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Dec 31, 2024
Rollup merge of rust-lang#134956 - compiler-errors:format-args-hidden-chars, r=jieyouxu

Account for C string literals and `format_args` in `HiddenUnicodeCodepoints` lint

This is stacked on rust-lang#134955, and either that can land first or both of them can land together here. I split this out because this is a bit more involved of an impl.

Fixes rust-lang#94945
@rustbot rustbot added this to the 1.85.0 milestone Dec 31, 2024
github-actions bot pushed a commit to tautschnig/verify-rust-std that referenced this pull request Mar 11, 2025
…iaskrgr

Rollup of 4 pull requests

Successful merges:

 - rust-lang#134610 (Format `build.toml` consistently in platform support docs)
 - rust-lang#134918 (Windows: Enable issue 70093 link tests)
 - rust-lang#134953 (Fix doc for read&write unaligned in zst operation)
 - rust-lang#134956 (Account for C string literals and `format_args` in `HiddenUnicodeCodepoints` lint)

r? `@ghost`
`@rustbot` modify labels: rollup
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
A-lints Area: Lints (warnings about flaws in source code) such as unused_mut. L-text_direction_codepoint_in_literal Lint: text_direction_codepoint_in_literal 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.

Bidi Trojan Source Linter Bypassed in Format Strings
4 participants