Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 32ab2e6

Browse files
committedAug 2, 2024
Auto merge of rust-lang#128556 - matthiaskrgr:rollup-zm5bokt, r=matthiaskrgr
Rollup of 6 pull requests Successful merges: - rust-lang#122049 (Promote riscv64gc-unknown-linux-musl to tier 2) - rust-lang#125558 (Tweak type inference for `const` operands in inline asm) - rust-lang#126704 (Added SHA512, SM3, SM4 target-features and `sha512_sm_x86` feature gate) - rust-lang#128161 (nested aux-build in tests/rustdoc/ tests) - rust-lang#128483 (Still more `cfg` cleanups) - rust-lang#128528 (Finish removing `has_cpuid`) r? `@ghost` `@rustbot` modify labels: rollup
2 parents f82eb4d + c6e838e commit 32ab2e6

File tree

71 files changed

+876
-488
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

71 files changed

+876
-488
lines changed
 

‎compiler/rustc_hir_typeck/src/lib.rs

+4-5
Original file line numberDiff line numberDiff line change
@@ -265,11 +265,10 @@ fn infer_type_if_missing<'tcx>(fcx: &FnCtxt<'_, 'tcx>, node: Node<'tcx>) -> Opti
265265
Node::Expr(&hir::Expr { kind: hir::ExprKind::InlineAsm(asm), span, .. })
266266
| Node::Item(&hir::Item { kind: hir::ItemKind::GlobalAsm(asm), span, .. }) => {
267267
asm.operands.iter().find_map(|(op, _op_sp)| match op {
268-
hir::InlineAsmOperand::Const { anon_const } if anon_const.hir_id == id => {
269-
// Inline assembly constants must be integers.
270-
Some(fcx.next_int_var())
271-
}
272-
hir::InlineAsmOperand::SymFn { anon_const } if anon_const.hir_id == id => {
268+
hir::InlineAsmOperand::Const { anon_const }
269+
| hir::InlineAsmOperand::SymFn { anon_const }
270+
if anon_const.hir_id == id =>
271+
{
273272
Some(fcx.next_ty_var(span))
274273
}
275274
_ => None,

‎compiler/rustc_parse/src/parser/attr.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ use rustc_span::{sym, BytePos, Span};
88
use thin_vec::ThinVec;
99
use tracing::debug;
1010

11-
use super::{AttrWrapper, Capturing, FnParseMode, ForceCollect, Parser, PathStyle};
11+
use super::{AttrWrapper, Capturing, FnParseMode, ForceCollect, Parser, ParserRange, PathStyle};
1212
use crate::{errors, fluent_generated as fluent, maybe_whole};
1313

1414
// Public for rustfmt usage
@@ -313,8 +313,8 @@ impl<'a> Parser<'a> {
313313
// inner attribute, for possible later processing in a `LazyAttrTokenStream`.
314314
if let Capturing::Yes = self.capture_state.capturing {
315315
let end_pos = self.num_bump_calls;
316-
let range = start_pos..end_pos;
317-
self.capture_state.inner_attr_ranges.insert(attr.id, range);
316+
let parser_range = ParserRange(start_pos..end_pos);
317+
self.capture_state.inner_attr_parser_ranges.insert(attr.id, parser_range);
318318
}
319319
attrs.push(attr);
320320
} else {
There was a problem loading the remainder of the diff.

0 commit comments

Comments
 (0)
Failed to load comments.