os-rust/tests
Jubilee fc0136e4f4
Rollup merge of #126922 - asquared31415:asm_binary_label, r=estebank
add lint for inline asm labels that look like binary

fixes #94426

Due to a bug/feature in LLVM, labels composed of only the digits `0` and `1` can sometimes be confused with binary literals, even if a binary literal would not be valid in that position.

This PR adds detection for such labels and also as a drive-by change, adds a note to cases such as `asm!(include_str!("file"))` that the label that it found came from an expansion of a macro, it wasn't found in the source code.

I expect this PR to upset some people that were using labels `0:` or `1:` without issue because they never hit the case where LLVM got it wrong, but adding a heuristic to the lint to prevent this is not feasible - it would involve writing a whole assembly parser for every target that we have assembly support for.

[zulip discussion](https://rust-lang.zulipchat.com/#narrow/stream/238009-t-compiler.2Fmeetings/topic/.5Bweekly.5D.202024-06-20/near/445870628)

r? ``@estebank``
2024-07-12 13:47:05 -07:00
..
assembly Always preserve user-written comments in assembly 2024-07-02 21:41:59 -04:00
auxiliary
codegen Use the aligned size for alloca at ret when the pass mode is cast. 2024-07-02 06:33:40 +08:00
codegen-units Avoid MIR bloat in inlining 2024-07-01 05:17:13 -07:00
coverage coverage. Fix panic when generating mcdc code for inlined functions 2024-07-09 14:28:40 +08:00
coverage-run-rustdoc coverage: Extract hole spans from HIR instead of MIR 2024-07-08 21:22:56 +10:00
crashes Avoid follow-up errors and ICEs after missing lifetime errors on data structures 2024-07-11 11:00:15 +00:00
debuginfo Add Natvis visualiser and debuginfo tests for f16 2024-07-09 03:47:50 +01:00
incremental Auto merge of #126409 - pacak:incr-uplorry, r=michaelwoerister 2024-06-20 09:06:16 +00:00
mir-opt Rollup merge of #126502 - cuviper:dump-mir-exclude-alloc-bytes, r=estebank 2024-07-12 13:47:05 -07:00
pretty Mark format! with must_use hint 2024-07-06 14:24:20 +02:00
run-make Rollup merge of #127605 - nikic:remove-extern-wasm, r=oli-obk 2024-07-11 17:01:41 +02:00
run-pass-valgrind rustfmt tests/run-pass-valgrind/. 2024-06-04 09:53:02 +10:00
rustdoc Migrate tests to use -Znext-solver 2024-06-30 17:08:45 +00:00
rustdoc-gui Don't call switch-theme function 2024-06-29 11:56:06 +02:00
rustdoc-js rustdoc-search: use lowercase, non-normalized name for type search 2024-06-09 11:56:52 -07:00
rustdoc-js-std Update tests 2024-06-07 11:55:52 +08:00
rustdoc-json rustdoc-json: add trait/type alias tests 2024-07-07 15:02:30 +01:00
rustdoc-ui Auto merge of #127311 - oli-obk:do_not_count_errors, r=compiler-errors 2024-07-11 11:51:33 +00:00
ui Rollup merge of #126922 - asquared31415:asm_binary_label, r=estebank 2024-07-12 13:47:05 -07:00
ui-fulldeps Always use a colon in //@ normalize-*: headers 2024-07-11 12:23:44 +10:00
COMPILER_TESTS.md