authorbors <bors@rust-lang.org> 2026-01-27 01:51:41 UTC
committerbors <bors@rust-lang.org> 2026-01-27 01:51:41 UTC
logebf13cca58b551b83133d4895e123f7d1e795111
tree6f12432bf746502b599acb1ce7e116cfae9064f2
parentb3cda168c8afd5c4240a9477f6a7f54e70e2589a
parent2f8f4acbd67d95c6fc706ffc1d1bd7b5166d809b

Auto merge of #151716 - Zalathar:rollup-kd2N5CM, r=Zalathar

Rollup of 12 pull requests Successful merges: - rust-lang/rust#147996 (Stabilize ppc inline assembly) - rust-lang/rust#148718 (Do not mention `-Zmacro-backtrace` for std macros that are a wrapper around a compiler intrinsic) - rust-lang/rust#151137 (checksum-freshness: Fix invalid checksum calculation for binary files) - rust-lang/rust#151680 (Update backtrace and windows-bindgen) - rust-lang/rust#150863 (Adds two new Tier 3 targets - `aarch64v8r-unknown-none{,-softfloat}`) - rust-lang/rust#151040 (Don't expose redundant information in `rustc_public`'s `LayoutShape`) - rust-lang/rust#151383 (remove `#[deprecated]` from unstable & internal `SipHasher13` and `24` types) - rust-lang/rust#151529 (lint: Use rustc_apfloat for `overflowing_literals`, add f16 and f128) - rust-lang/rust#151669 (rename uN::{gather,scatter}_bits to uN::{extract,deposit}_bits) - rust-lang/rust#151689 (Fix broken Xtensa installation link) - rust-lang/rust#151699 (Update books) - rust-lang/rust#151700 (os allow missing_docs)

197 files changed, 880 insertions(+), 750 deletions(-)

Cargo.lock+4-3
......@@ -4170,6 +4170,7 @@ version = "0.0.0"
41704170dependencies = [
41714171 "bitflags",
41724172 "rustc_abi",
4173 "rustc_apfloat",
41734174 "rustc_ast",
41744175 "rustc_ast_pretty",
41754176 "rustc_attr_parsing",
......@@ -6419,13 +6420,13 @@ dependencies = [
64196420
64206421[[package]]
64216422name = "windows-bindgen"
6422version = "0.61.1"
6423version = "0.66.0"
64236424source = "registry+https://github.com/rust-lang/crates.io-index"
6424checksum = "9b4e97b01190d32f268a2dfbd3f006f77840633746707fbe40bcee588108a231"
6425checksum = "81b7ec123a4eadd44d1f44f76804316b477b2537abed9a2ab950b3c54afa1fcf"
64256426dependencies = [
64266427 "serde",
64276428 "serde_json",
6428 "windows-threading 0.1.0",
6429 "windows-threading 0.2.1",
64296430]
64306431
64316432[[package]]
compiler/rustc_ast_lowering/src/asm.rs+2
......@@ -51,6 +51,8 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
5151 | asm::InlineAsmArch::LoongArch32
5252 | asm::InlineAsmArch::LoongArch64
5353 | asm::InlineAsmArch::S390x
54 | asm::InlineAsmArch::PowerPC
55 | asm::InlineAsmArch::PowerPC64
5456 );
5557 if !is_stable
5658 && !self.tcx.features().asm_experimental_arch()
compiler/rustc_builtin_macros/src/source_util.rs+9-1
......@@ -275,7 +275,15 @@ fn load_binary_file(
275275 }
276276 };
277277 match cx.source_map().load_binary_file(&resolved_path) {
278 Ok(data) => Ok(data),
278 Ok(data) => {
279 cx.sess
280 .psess
281 .file_depinfo
282 .borrow_mut()
283 .insert(Symbol::intern(&resolved_path.to_string_lossy()));
284
285 Ok(data)
286 }
279287 Err(io_err) => {
280288 let mut err = cx.dcx().struct_span_err(
281289 macro_span,
compiler/rustc_expand/src/base.rs+13-1
......@@ -849,6 +849,9 @@ pub struct SyntaxExtension {
849849 /// Should debuginfo for the macro be collapsed to the outermost expansion site (in other
850850 /// words, was the macro definition annotated with `#[collapse_debuginfo]`)?
851851 pub collapse_debuginfo: bool,
852 /// Suppresses the "this error originates in the macro" note when a diagnostic points at this
853 /// macro.
854 pub hide_backtrace: bool,
852855}
853856
854857impl SyntaxExtension {
......@@ -882,6 +885,7 @@ impl SyntaxExtension {
882885 allow_internal_unsafe: false,
883886 local_inner_macros: false,
884887 collapse_debuginfo: false,
888 hide_backtrace: false,
885889 }
886890 }
887891
......@@ -912,6 +916,12 @@ impl SyntaxExtension {
912916 collapse_table[flag as usize][attr as usize]
913917 }
914918
919 fn get_hide_backtrace(attrs: &[hir::Attribute]) -> bool {
920 // FIXME(estebank): instead of reusing `#[rustc_diagnostic_item]` as a proxy, introduce a
921 // new attribute purely for this under the `#[diagnostic]` namespace.
922 ast::attr::find_by_name(attrs, sym::rustc_diagnostic_item).is_some()
923 }
924
915925 /// Constructs a syntax extension with the given properties
916926 /// and other properties converted from attributes.
917927 pub fn new(
......@@ -948,6 +958,7 @@ impl SyntaxExtension {
948958 // Not a built-in macro
949959 None => (None, helper_attrs),
950960 };
961 let hide_backtrace = builtin_name.is_some() || Self::get_hide_backtrace(attrs);
951962
952963 let stability = find_attr!(attrs, AttributeKind::Stability { stability, .. } => *stability);
953964
......@@ -982,6 +993,7 @@ impl SyntaxExtension {
982993 allow_internal_unsafe,
983994 local_inner_macros,
984995 collapse_debuginfo,
996 hide_backtrace,
985997 }
986998 }
987999
......@@ -1061,7 +1073,7 @@ impl SyntaxExtension {
10611073 self.allow_internal_unsafe,
10621074 self.local_inner_macros,
10631075 self.collapse_debuginfo,
1064 self.builtin_name.is_some(),
1076 self.hide_backtrace,
10651077 )
10661078 }
10671079}
compiler/rustc_interface/src/passes.rs+14-15
......@@ -9,6 +9,7 @@ use rustc_ast::{self as ast, CRATE_NODE_ID};
99use rustc_attr_parsing::{AttributeParser, Early, ShouldEmit};
1010use rustc_codegen_ssa::traits::CodegenBackend;
1111use rustc_codegen_ssa::{CodegenResults, CrateInfo};
12use rustc_data_structures::indexmap::IndexMap;
1213use rustc_data_structures::jobserver::Proxy;
1314use rustc_data_structures::steal::Steal;
1415use rustc_data_structures::sync::{AppendOnlyIndexVec, FreezeLock, WorkerLocal};
......@@ -584,7 +585,7 @@ fn write_out_deps(tcx: TyCtxt<'_>, outputs: &OutputFilenames, out_filenames: &[P
584585 let result: io::Result<()> = try {
585586 // Build a list of files used to compile the output and
586587 // write Makefile-compatible dependency rules
587 let mut files: Vec<(String, u64, Option<SourceFileHash>)> = sess
588 let mut files: IndexMap<String, (u64, Option<SourceFileHash>)> = sess
588589 .source_map()
589590 .files()
590591 .iter()
......@@ -593,10 +594,12 @@ fn write_out_deps(tcx: TyCtxt<'_>, outputs: &OutputFilenames, out_filenames: &[P
593594 .map(|fmap| {
594595 (
595596 escape_dep_filename(&fmap.name.prefer_local_unconditionally().to_string()),
596 // This needs to be unnormalized,
597 // as external tools wouldn't know how rustc normalizes them
598 fmap.unnormalized_source_len as u64,
599 fmap.checksum_hash,
597 (
598 // This needs to be unnormalized,
599 // as external tools wouldn't know how rustc normalizes them
600 fmap.unnormalized_source_len as u64,
601 fmap.checksum_hash,
602 ),
600603 )
601604 })
602605 .collect();
......@@ -614,7 +617,7 @@ fn write_out_deps(tcx: TyCtxt<'_>, outputs: &OutputFilenames, out_filenames: &[P
614617 fn hash_iter_files<P: AsRef<Path>>(
615618 it: impl Iterator<Item = P>,
616619 checksum_hash_algo: Option<SourceFileHashAlgorithm>,
617 ) -> impl Iterator<Item = (P, u64, Option<SourceFileHash>)> {
620 ) -> impl Iterator<Item = (P, (u64, Option<SourceFileHash>))> {
618621 it.map(move |path| {
619622 match checksum_hash_algo.and_then(|algo| {
620623 fs::File::open(path.as_ref())
......@@ -630,8 +633,8 @@ fn write_out_deps(tcx: TyCtxt<'_>, outputs: &OutputFilenames, out_filenames: &[P
630633 })
631634 .ok()
632635 }) {
633 Some((file_len, checksum)) => (path, file_len, Some(checksum)),
634 None => (path, 0, None),
636 Some((file_len, checksum)) => (path, (file_len, Some(checksum))),
637 None => (path, (0, None)),
635638 }
636639 })
637640 }
......@@ -705,18 +708,14 @@ fn write_out_deps(tcx: TyCtxt<'_>, outputs: &OutputFilenames, out_filenames: &[P
705708 file,
706709 "{}: {}\n",
707710 path.display(),
708 files
709 .iter()
710 .map(|(path, _file_len, _checksum_hash_algo)| path.as_str())
711 .intersperse(" ")
712 .collect::<String>()
711 files.keys().map(String::as_str).intersperse(" ").collect::<String>()
713712 )?;
714713 }
715714
716715 // Emit a fake target for each input file to the compilation. This
717716 // prevents `make` from spitting out an error if a file is later
718717 // deleted. For more info see #28735
719 for (path, _file_len, _checksum_hash_algo) in &files {
718 for path in files.keys() {
720719 writeln!(file, "{path}:")?;
721720 }
722721
......@@ -745,7 +744,7 @@ fn write_out_deps(tcx: TyCtxt<'_>, outputs: &OutputFilenames, out_filenames: &[P
745744 if sess.opts.unstable_opts.checksum_hash_algorithm().is_some() {
746745 files
747746 .iter()
748 .filter_map(|(path, file_len, hash_algo)| {
747 .filter_map(|(path, (file_len, hash_algo))| {
749748 hash_algo.map(|hash_algo| (path, file_len, hash_algo))
750749 })
751750 .try_for_each(|(path, file_len, checksum_hash)| {
compiler/rustc_lint/Cargo.toml+1
......@@ -7,6 +7,7 @@ edition = "2024"
77# tidy-alphabetical-start
88bitflags = "2.4.1"
99rustc_abi = { path = "../rustc_abi" }
10rustc_apfloat = "0.2.0"
1011rustc_ast = { path = "../rustc_ast" }
1112rustc_ast_pretty = { path = "../rustc_ast_pretty" }
1213rustc_attr_parsing = { path = "../rustc_attr_parsing" }
compiler/rustc_lint/src/types/literal.rs+22-13
......@@ -1,10 +1,12 @@
11use hir::{ExprKind, Node};
22use rustc_abi::{Integer, Size};
3use rustc_apfloat::Float;
4use rustc_apfloat::ieee::{DoubleS, HalfS, IeeeFloat, QuadS, Semantics, SingleS};
35use rustc_hir::{HirId, attrs};
46use rustc_middle::ty::Ty;
57use rustc_middle::ty::layout::IntegerExt;
68use rustc_middle::{bug, ty};
7use rustc_span::Span;
9use rustc_span::{Span, Symbol};
810use {rustc_ast as ast, rustc_hir as hir};
911
1012use crate::LateContext;
......@@ -383,6 +385,13 @@ fn lint_uint_literal<'tcx>(
383385 }
384386}
385387
388/// `None` if `v` does not parse as the float type, otherwise indicates whether a literal rounds
389/// to infinity.
390fn float_is_infinite<S: Semantics>(v: Symbol) -> Option<bool> {
391 let x: IeeeFloat<S> = v.as_str().parse().ok()?;
392 Some(x.is_infinite())
393}
394
386395pub(crate) fn lint_literal<'tcx>(
387396 cx: &LateContext<'tcx>,
388397 type_limits: &TypeLimits,
......@@ -405,18 +414,18 @@ pub(crate) fn lint_literal<'tcx>(
405414 lint_uint_literal(cx, hir_id, span, lit, t)
406415 }
407416 ty::Float(t) => {
408 let (is_infinite, sym) = match lit.node {
409 ast::LitKind::Float(v, _) => match t {
410 // FIXME(f16_f128): add this check once `is_infinite` is reliable (ABI
411 // issues resolved).
412 ty::FloatTy::F16 => (Ok(false), v),
413 ty::FloatTy::F32 => (v.as_str().parse().map(f32::is_infinite), v),
414 ty::FloatTy::F64 => (v.as_str().parse().map(f64::is_infinite), v),
415 ty::FloatTy::F128 => (Ok(false), v),
416 },
417 _ => bug!(),
417 let ast::LitKind::Float(v, _) = lit.node else {
418 bug!();
418419 };
419 if is_infinite == Ok(true) {
420
421 let is_infinite = match t {
422 ty::FloatTy::F16 => float_is_infinite::<HalfS>(v),
423 ty::FloatTy::F32 => float_is_infinite::<SingleS>(v),
424 ty::FloatTy::F64 => float_is_infinite::<DoubleS>(v),
425 ty::FloatTy::F128 => float_is_infinite::<QuadS>(v),
426 };
427
428 if is_infinite == Some(true) {
420429 cx.emit_span_lint(
421430 OVERFLOWING_LITERALS,
422431 span,
......@@ -426,7 +435,7 @@ pub(crate) fn lint_literal<'tcx>(
426435 .sess()
427436 .source_map()
428437 .span_to_snippet(lit.span)
429 .unwrap_or_else(|_| sym.to_string()),
438 .unwrap_or_else(|_| v.to_string()),
430439 },
431440 );
432441 }
compiler/rustc_public/src/abi.rs+18-1
......@@ -188,10 +188,27 @@ pub enum VariantsShape {
188188 tag: Scalar,
189189 tag_encoding: TagEncoding,
190190 tag_field: usize,
191 variants: Vec<LayoutShape>,
191 variants: Vec<VariantFields>,
192192 },
193193}
194194
195#[derive(Clone, Debug, PartialEq, Eq, Hash, Serialize)]
196pub struct VariantFields {
197 /// Offsets for the first byte of each field,
198 /// ordered to match the source definition order.
199 /// I.e.: It follows the same order as [super::ty::VariantDef::fields()].
200 /// This vector does not go in increasing order.
201 pub offsets: Vec<Size>,
202}
203
204impl VariantFields {
205 pub fn fields_by_offset_order(&self) -> Vec<FieldIdx> {
206 let mut indices = (0..self.offsets.len()).collect::<Vec<_>>();
207 indices.sort_by_key(|idx| self.offsets[*idx]);
208 indices
209 }
210}
211
195212#[derive(Clone, Debug, PartialEq, Eq, Hash, Serialize)]
196213pub enum TagEncoding {
197214 /// The tag directly stores the discriminant, but possibly with a smaller layout
compiler/rustc_public/src/unstable/convert/stable/abi.rs+10-2
......@@ -11,7 +11,7 @@ use rustc_target::callconv;
1111use crate::abi::{
1212 AddressSpace, ArgAbi, CallConvention, FieldsShape, FloatLength, FnAbi, IntegerLength,
1313 IntegerType, Layout, LayoutShape, PassMode, Primitive, ReprFlags, ReprOptions, Scalar,
14 TagEncoding, TyAndLayout, ValueAbi, VariantsShape, WrappingRange,
14 TagEncoding, TyAndLayout, ValueAbi, VariantFields, VariantsShape, WrappingRange,
1515};
1616use crate::compiler_interface::BridgeTys;
1717use crate::target::MachineSize as Size;
......@@ -213,7 +213,15 @@ impl<'tcx> Stable<'tcx> for rustc_abi::Variants<rustc_abi::FieldIdx, rustc_abi::
213213 tag: tag.stable(tables, cx),
214214 tag_encoding: tag_encoding.stable(tables, cx),
215215 tag_field: tag_field.stable(tables, cx),
216 variants: variants.iter().as_slice().stable(tables, cx),
216 variants: variants
217 .iter()
218 .map(|v| match &v.fields {
219 rustc_abi::FieldsShape::Arbitrary { offsets, .. } => VariantFields {
220 offsets: offsets.iter().as_slice().stable(tables, cx),
221 },
222 _ => panic!("variant layout should be Arbitrary"),
223 })
224 .collect(),
217225 }
218226 }
219227 }
compiler/rustc_target/src/spec/mod.rs+2
......@@ -1709,6 +1709,8 @@ supported_targets! {
17091709 ("aarch64-unknown-none-softfloat", aarch64_unknown_none_softfloat),
17101710 ("aarch64_be-unknown-none-softfloat", aarch64_be_unknown_none_softfloat),
17111711 ("aarch64-unknown-nuttx", aarch64_unknown_nuttx),
1712 ("aarch64v8r-unknown-none", aarch64v8r_unknown_none),
1713 ("aarch64v8r-unknown-none-softfloat", aarch64v8r_unknown_none_softfloat),
17121714
17131715 ("x86_64-fortanix-unknown-sgx", x86_64_fortanix_unknown_sgx),
17141716
compiler/rustc_target/src/spec/targets/aarch64v8r_unknown_none.rs created+37
......@@ -0,0 +1,37 @@
1use crate::spec::{
2 Arch, Cc, LinkerFlavor, Lld, PanicStrategy, RelocModel, SanitizerSet, StackProbeType, Target,
3 TargetMetadata, TargetOptions,
4};
5
6pub(crate) fn target() -> Target {
7 let opts = TargetOptions {
8 // based off the aarch64-unknown-none target at time of addition
9 linker_flavor: LinkerFlavor::Gnu(Cc::No, Lld::Yes),
10 linker: Some("rust-lld".into()),
11 supported_sanitizers: SanitizerSet::KCFI | SanitizerSet::KERNELADDRESS,
12 relocation_model: RelocModel::Static,
13 disable_redzone: true,
14 max_atomic_width: Some(128),
15 stack_probes: StackProbeType::Inline,
16 panic_strategy: PanicStrategy::Abort,
17 default_uwtable: true,
18
19 // deviations from aarch64-unknown-none: `+v8a` -> `+v8r`; `+v8r` implies `+neon`
20 features: "+v8r,+strict-align".into(),
21 ..Default::default()
22 };
23 Target {
24 llvm_target: "aarch64-unknown-none".into(),
25 metadata: TargetMetadata {
26 description: Some("Bare Armv8-R AArch64, hardfloat".into()),
27 tier: Some(3),
28 host_tools: Some(false),
29 std: Some(false),
30 },
31 pointer_width: 64,
32 // $ clang-21 -S -emit-llvm -target aarch64 -mcpu=cortex-r82 stub.c
33 data_layout: "e-m:e-p270:32:32-p271:32:32-p272:64:64-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128-Fn32".into(),
34 arch: Arch::AArch64,
35 options: opts,
36 }
37}
compiler/rustc_target/src/spec/targets/aarch64v8r_unknown_none_softfloat.rs created+36
......@@ -0,0 +1,36 @@
1use crate::spec::{
2 Abi, Arch, Cc, LinkerFlavor, Lld, PanicStrategy, RelocModel, SanitizerSet, StackProbeType,
3 Target, TargetMetadata, TargetOptions,
4};
5
6pub(crate) fn target() -> Target {
7 let opts = TargetOptions {
8 abi: Abi::SoftFloat,
9 linker_flavor: LinkerFlavor::Gnu(Cc::No, Lld::Yes),
10 linker: Some("rust-lld".into()),
11 relocation_model: RelocModel::Static,
12 disable_redzone: true,
13 max_atomic_width: Some(128),
14 supported_sanitizers: SanitizerSet::KCFI | SanitizerSet::KERNELADDRESS,
15 stack_probes: StackProbeType::Inline,
16 panic_strategy: PanicStrategy::Abort,
17 default_uwtable: true,
18
19 // deviations from aarch64-unknown-none: `+v8a` -> `+v8r`
20 features: "+v8r,+strict-align,-neon".into(),
21 ..Default::default()
22 };
23 Target {
24 llvm_target: "aarch64-unknown-none".into(),
25 metadata: TargetMetadata {
26 description: Some("Bare Armv8-R AArch64, softfloat".into()),
27 tier: Some(3),
28 host_tools: Some(false),
29 std: Some(false),
30 },
31 pointer_width: 64,
32 data_layout: "e-m:e-p270:32:32-p271:32:32-p272:64:64-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128-Fn32".into(),
33 arch: Arch::AArch64,
34 options: opts,
35 }
36}
library/Cargo.lock+7-7
......@@ -346,7 +346,7 @@ dependencies = [
346346 "vex-sdk",
347347 "wasi 0.11.1+wasi-snapshot-preview1",
348348 "wasi 0.14.4+wasi-0.2.4",
349 "windows-targets 0.0.0",
349 "windows-link 0.0.0",
350350]
351351
352352[[package]]
......@@ -427,6 +427,10 @@ dependencies = [
427427 "wit-bindgen",
428428]
429429
430[[package]]
431name = "windows-link"
432version = "0.0.0"
433
430434[[package]]
431435name = "windows-link"
432436version = "0.2.1"
......@@ -439,20 +443,16 @@ version = "0.60.2"
439443source = "registry+https://github.com/rust-lang/crates.io-index"
440444checksum = "f2f500e4d28234f72040990ec9d39e3a6b950f9f22d3dba18416c35882612bcb"
441445dependencies = [
442 "windows-targets 0.53.5",
446 "windows-targets",
443447]
444448
445[[package]]
446name = "windows-targets"
447version = "0.0.0"
448
449449[[package]]
450450name = "windows-targets"
451451version = "0.53.5"
452452source = "registry+https://github.com/rust-lang/crates.io-index"
453453checksum = "4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3"
454454dependencies = [
455 "windows-link",
455 "windows-link 0.2.1",
456456 "windows_aarch64_gnullvm",
457457 "windows_aarch64_msvc",
458458 "windows_i686_gnu",
library/Cargo.toml+1-1
......@@ -12,7 +12,7 @@ members = [
1212exclude = [
1313 # stdarch has its own Cargo workspace
1414 "stdarch",
15 "windows_targets"
15 "windows_link"
1616]
1717
1818[profile.release.package.compiler_builtins]
library/alloctests/tests/c_str2.rs+1-5
......@@ -3,9 +3,7 @@ use alloc::rc::Rc;
33use alloc::sync::Arc;
44use core::assert_matches;
55use core::ffi::{CStr, FromBytesUntilNulError, c_char};
6#[allow(deprecated)]
7use core::hash::SipHasher13 as DefaultHasher;
8use core::hash::{Hash, Hasher};
6use core::hash::{Hash, Hasher, SipHasher13 as DefaultHasher};
97
108#[test]
119fn c_to_rust() {
......@@ -57,11 +55,9 @@ fn equal_hash() {
5755 let ptr = data.as_ptr() as *const c_char;
5856 let cstr: &'static CStr = unsafe { CStr::from_ptr(ptr) };
5957
60 #[allow(deprecated)]
6158 let mut s = DefaultHasher::new();
6259 cstr.hash(&mut s);
6360 let cstr_hash = s.finish();
64 #[allow(deprecated)]
6561 let mut s = DefaultHasher::new();
6662 CString::new(&data[..data.len() - 1]).unwrap().hash(&mut s);
6763 let cstring_hash = s.finish();
library/backtrace+1-1
......@@ -1 +1 @@
1Subproject commit b65ab935fb2e0d59dba8966ffca09c9cc5a5f57c
1Subproject commit 28ec93b503bf0410745bc3d571bf3dc1caac3019
library/core/src/fmt/float.rs+7-1
......@@ -13,8 +13,14 @@ macro_rules! impl_general_format {
1313 ($($t:ident)*) => {
1414 $(impl GeneralFormat for $t {
1515 fn already_rounded_value_should_use_exponential(&self) -> bool {
16 // `max_abs` rounds to infinity for `f16`. This is fine to save us from a more
17 // complex macro, it just means a positive-exponent `f16` will never print as
18 // scientific notation by default (reasonably, the max is 65504.0).
19 #[allow(overflowing_literals)]
20 let max_abs = 1e+16;
21
1622 let abs = $t::abs(*self);
17 (abs != 0.0 && abs < 1e-4) || abs >= 1e+16
23 (abs != 0.0 && abs < 1e-4) || abs >= max_abs
1824 }
1925 })*
2026 }
library/core/src/hash/mod.rs-1
......@@ -87,7 +87,6 @@
8787#[allow(deprecated)]
8888pub use self::sip::SipHasher;
8989#[unstable(feature = "hashmap_internals", issue = "none")]
90#[allow(deprecated)]
9190#[doc(hidden)]
9291pub use self::sip::SipHasher13;
9392use crate::{fmt, marker};
library/core/src/hash/sip.rs+6-7
......@@ -11,8 +11,11 @@ use crate::{cmp, ptr};
1111/// (e.g., `collections::HashMap` uses it by default).
1212///
1313/// See: <https://github.com/veorq/SipHash>
14#[unstable(feature = "hashmap_internals", issue = "none")]
15#[deprecated(since = "1.13.0", note = "use `std::hash::DefaultHasher` instead")]
14#[unstable(
15 feature = "hashmap_internals",
16 issue = "none",
17 reason = "use `std::hash::DefaultHasher` instead"
18)]
1619#[derive(Debug, Clone, Default)]
1720#[doc(hidden)]
1821pub struct SipHasher13 {
......@@ -23,7 +26,6 @@ pub struct SipHasher13 {
2326///
2427/// See: <https://github.com/veorq/SipHash>
2528#[unstable(feature = "hashmap_internals", issue = "none")]
26#[deprecated(since = "1.13.0", note = "use `std::hash::DefaultHasher` instead")]
2729#[derive(Debug, Clone, Default)]
2830struct SipHasher24 {
2931 hasher: Hasher<Sip24Rounds>,
......@@ -137,8 +139,7 @@ unsafe fn u8to64_le(buf: &[u8], start: usize, len: usize) -> u64 {
137139 out |= (unsafe { *buf.get_unchecked(start + i) } as u64) << (i * 8);
138140 i += 1;
139141 }
140 //FIXME(fee1-dead): use debug_assert_eq
141 debug_assert!(i == len);
142 debug_assert_eq!(i, len);
142143 out
143144}
144145
......@@ -167,7 +168,6 @@ impl SipHasher13 {
167168 #[inline]
168169 #[unstable(feature = "hashmap_internals", issue = "none")]
169170 #[rustc_const_unstable(feature = "const_default", issue = "143894")]
170 #[deprecated(since = "1.13.0", note = "use `std::hash::DefaultHasher` instead")]
171171 pub const fn new() -> SipHasher13 {
172172 SipHasher13::new_with_keys(0, 0)
173173 }
......@@ -176,7 +176,6 @@ impl SipHasher13 {
176176 #[inline]
177177 #[unstable(feature = "hashmap_internals", issue = "none")]
178178 #[rustc_const_unstable(feature = "const_default", issue = "143894")]
179 #[deprecated(since = "1.13.0", note = "use `std::hash::DefaultHasher` instead")]
180179 pub const fn new_with_keys(key0: u64, key1: u64) -> SipHasher13 {
181180 SipHasher13 { hasher: Hasher::new_with_keys(key0, key1) }
182181 }
library/core/src/num/int_bits.rs+10-10
......@@ -1,12 +1,12 @@
1//! Implementations for `uN::gather_bits` and `uN::scatter_bits`
1//! Implementations for `uN::extract_bits` and `uN::deposit_bits`
22//!
33//! For the purposes of this implementation, the operations can be thought
44//! of as operating on the input bits as a list, starting from the least
5//! significant bit. Gathering is like `Vec::retain` that deletes bits
6//! where the mask has a zero. Scattering is like doing the inverse by
7//! inserting the zeros that gathering would delete.
5//! significant bit. Extraction is like `Vec::retain` that deletes bits
6//! where the mask has a zero. Deposition is like doing the inverse by
7//! inserting the zeros that extraction would delete.
88//!
9//! Key observation: Each bit that is gathered/scattered needs to be
9//! Key observation: Each extracted or deposited bit needs to be
1010//! shifted by the count of zeros up to the corresponding mask bit.
1111//!
1212//! With that in mind, the general idea is to decompose the operation into
......@@ -14,7 +14,7 @@
1414//! of the bits by `n = 1 << stage`. The masks for each stage are computed
1515//! via prefix counts of zeros in the mask.
1616//!
17//! # Gathering
17//! # Extraction
1818//!
1919//! Consider the input as a sequence of runs of data (bitstrings A,B,C,...),
2020//! split by fixed-width groups of zeros ('.'), initially at width `n = 1`.
......@@ -36,9 +36,9 @@
3636//! ........abbbcccccddeghh
3737//! ```
3838//!
39//! # Scattering
39//! # Deposition
4040//!
41//! For `scatter_bits`, the stages are reversed. We start with a single run of
41//! For `deposit_bits`, the stages are reversed. We start with a single run of
4242//! data in the low bits. Each stage then splits each run of data in two by
4343//! shifting part of it left by `n`, which is halved each stage.
4444//! ```text
......@@ -100,7 +100,7 @@ macro_rules! uint_impl {
100100 }
101101
102102 #[inline(always)]
103 pub(in super::super) const fn gather_impl(mut x: $U, sparse: $U) -> $U {
103 pub(in super::super) const fn extract_impl(mut x: $U, sparse: $U) -> $U {
104104 let masks = prepare(sparse);
105105 x &= sparse;
106106 let mut stage = 0;
......@@ -131,7 +131,7 @@ macro_rules! uint_impl {
131131 x
132132 }
133133 #[inline(always)]
134 pub(in super::super) const fn scatter_impl(mut x: $U, sparse: $U) -> $U {
134 pub(in super::super) const fn deposit_impl(mut x: $U, sparse: $U) -> $U {
135135 let masks = prepare(sparse);
136136 let mut stage = STAGES;
137137 while stage > 0 {
library/core/src/num/uint_macros.rs+8-8
......@@ -507,15 +507,15 @@ macro_rules! uint_impl {
507507 /// #![feature(uint_gather_scatter_bits)]
508508 #[doc = concat!("let n: ", stringify!($SelfT), " = 0b1011_1100;")]
509509 ///
510 /// assert_eq!(n.gather_bits(0b0010_0100), 0b0000_0011);
511 /// assert_eq!(n.gather_bits(0xF0), 0b0000_1011);
510 /// assert_eq!(n.extract_bits(0b0010_0100), 0b0000_0011);
511 /// assert_eq!(n.extract_bits(0xF0), 0b0000_1011);
512512 /// ```
513513 #[unstable(feature = "uint_gather_scatter_bits", issue = "149069")]
514514 #[must_use = "this returns the result of the operation, \
515515 without modifying the original"]
516516 #[inline]
517 pub const fn gather_bits(self, mask: Self) -> Self {
518 crate::num::int_bits::$ActualT::gather_impl(self as $ActualT, mask as $ActualT) as $SelfT
517 pub const fn extract_bits(self, mask: Self) -> Self {
518 crate::num::int_bits::$ActualT::extract_impl(self as $ActualT, mask as $ActualT) as $SelfT
519519 }
520520
521521 /// Returns an integer with the least significant bits of `self`
......@@ -524,15 +524,15 @@ macro_rules! uint_impl {
524524 /// #![feature(uint_gather_scatter_bits)]
525525 #[doc = concat!("let n: ", stringify!($SelfT), " = 0b1010_1101;")]
526526 ///
527 /// assert_eq!(n.scatter_bits(0b0101_0101), 0b0101_0001);
528 /// assert_eq!(n.scatter_bits(0xF0), 0b1101_0000);
527 /// assert_eq!(n.deposit_bits(0b0101_0101), 0b0101_0001);
528 /// assert_eq!(n.deposit_bits(0xF0), 0b1101_0000);
529529 /// ```
530530 #[unstable(feature = "uint_gather_scatter_bits", issue = "149069")]
531531 #[must_use = "this returns the result of the operation, \
532532 without modifying the original"]
533533 #[inline]
534 pub const fn scatter_bits(self, mask: Self) -> Self {
535 crate::num::int_bits::$ActualT::scatter_impl(self as $ActualT, mask as $ActualT) as $SelfT
534 pub const fn deposit_bits(self, mask: Self) -> Self {
535 crate::num::int_bits::$ActualT::deposit_impl(self as $ActualT, mask as $ActualT) as $SelfT
536536 }
537537
538538 /// Reverses the order of bits in the integer. The least significant bit becomes the most significant bit,
library/core/src/os/mod.rs+1
......@@ -1,6 +1,7 @@
11//! OS-specific functionality.
22
33#![unstable(feature = "darwin_objc", issue = "145496")]
4#![allow(missing_docs)]
45
56#[cfg(all(
67 doc,
library/core/src/result.rs+2-2
......@@ -1354,7 +1354,7 @@ impl<T, E> Result<T, E> {
13541354 /// let s: String = only_good_news().into_ok();
13551355 /// println!("{s}");
13561356 /// ```
1357 #[unstable(feature = "unwrap_infallible", reason = "newly added", issue = "61695")]
1357 #[unstable(feature = "unwrap_infallible", issue = "61695")]
13581358 #[inline]
13591359 #[rustc_allow_const_fn_unstable(const_precise_live_drops)]
13601360 #[rustc_const_unstable(feature = "const_convert", issue = "143773")]
......@@ -1391,7 +1391,7 @@ impl<T, E> Result<T, E> {
13911391 /// let error: String = only_bad_news().into_err();
13921392 /// println!("{error}");
13931393 /// ```
1394 #[unstable(feature = "unwrap_infallible", reason = "newly added", issue = "61695")]
1394 #[unstable(feature = "unwrap_infallible", issue = "61695")]
13951395 #[inline]
13961396 #[rustc_allow_const_fn_unstable(const_precise_live_drops)]
13971397 #[rustc_const_unstable(feature = "const_convert", issue = "143773")]
library/core/src/slice/mod.rs+2-2
......@@ -2520,7 +2520,7 @@ impl<T> [T] {
25202520 /// )));
25212521 /// assert_eq!(s.split_once(|&x| x == 0), None);
25222522 /// ```
2523 #[unstable(feature = "slice_split_once", reason = "newly added", issue = "112811")]
2523 #[unstable(feature = "slice_split_once", issue = "112811")]
25242524 #[inline]
25252525 pub fn split_once<F>(&self, pred: F) -> Option<(&[T], &[T])>
25262526 where
......@@ -2548,7 +2548,7 @@ impl<T> [T] {
25482548 /// )));
25492549 /// assert_eq!(s.rsplit_once(|&x| x == 0), None);
25502550 /// ```
2551 #[unstable(feature = "slice_split_once", reason = "newly added", issue = "112811")]
2551 #[unstable(feature = "slice_split_once", issue = "112811")]
25522552 #[inline]
25532553 pub fn rsplit_once<F>(&self, pred: F) -> Option<(&[T], &[T])>
25542554 where
library/coretests/benches/num/int_bits/mod.rs+2-2
......@@ -50,8 +50,8 @@ macro_rules! bench_mask_kind {
5050 ($mask_kind:ident, $mask:expr) => {
5151 mod $mask_kind {
5252 use super::{Data, ITERATIONS, U};
53 bench_template!(U::gather_bits, gather_bits, $mask);
54 bench_template!(U::scatter_bits, scatter_bits, $mask);
53 bench_template!(U::extract_bits, extract_bits, $mask);
54 bench_template!(U::deposit_bits, deposit_bits, $mask);
5555 }
5656 };
5757}
library/coretests/tests/num/uint_macros.rs+54-54
......@@ -127,50 +127,50 @@ macro_rules! uint_module {
127127 assert_eq_const_safe!($T: _1.swap_bytes(), _1);
128128 }
129129
130 fn test_gather_bits() {
131 assert_eq_const_safe!($T: $T::gather_bits(0b1010_0101, 0b0000_0011), 0b_0001);
132 assert_eq_const_safe!($T: $T::gather_bits(0b1010_0101, 0b0000_0110), 0b_0010);
133 assert_eq_const_safe!($T: $T::gather_bits(0b1010_0101, 0b0000_1100), 0b_0001);
134 assert_eq_const_safe!($T: $T::gather_bits(0b1010_0101, 0b0001_1000), 0b_0000);
135 assert_eq_const_safe!($T: $T::gather_bits(0b1010_0101, 0b0011_0000), 0b_0010);
136 assert_eq_const_safe!($T: $T::gather_bits(0b1010_0101, 0b0110_0000), 0b_0001);
137 assert_eq_const_safe!($T: $T::gather_bits(0b1010_0101, 0b1100_0000), 0b_0010);
138
139 assert_eq_const_safe!($T: A.gather_bits(_0), 0);
140 assert_eq_const_safe!($T: B.gather_bits(_0), 0);
141 assert_eq_const_safe!($T: C.gather_bits(_0), 0);
142 assert_eq_const_safe!($T: _0.gather_bits(A), 0);
143 assert_eq_const_safe!($T: _0.gather_bits(B), 0);
144 assert_eq_const_safe!($T: _0.gather_bits(C), 0);
145
146 assert_eq_const_safe!($T: A.gather_bits(_1), A);
147 assert_eq_const_safe!($T: B.gather_bits(_1), B);
148 assert_eq_const_safe!($T: C.gather_bits(_1), C);
149 assert_eq_const_safe!($T: _1.gather_bits(0b0010_0001), 0b0000_0011);
150 assert_eq_const_safe!($T: _1.gather_bits(0b0010_1100), 0b0000_0111);
151 assert_eq_const_safe!($T: _1.gather_bits(0b0111_1001), 0b0001_1111);
152 }
153
154 fn test_scatter_bits() {
155 assert_eq_const_safe!($T: $T::scatter_bits(0b1111, 0b1001_0110), 0b1001_0110);
156 assert_eq_const_safe!($T: $T::scatter_bits(0b0001, 0b1001_0110), 0b0000_0010);
157 assert_eq_const_safe!($T: $T::scatter_bits(0b0010, 0b1001_0110), 0b0000_0100);
158 assert_eq_const_safe!($T: $T::scatter_bits(0b0100, 0b1001_0110), 0b0001_0000);
159 assert_eq_const_safe!($T: $T::scatter_bits(0b1000, 0b1001_0110), 0b1000_0000);
160
161 assert_eq_const_safe!($T: A.scatter_bits(_0), 0);
162 assert_eq_const_safe!($T: B.scatter_bits(_0), 0);
163 assert_eq_const_safe!($T: C.scatter_bits(_0), 0);
164 assert_eq_const_safe!($T: _0.scatter_bits(A), 0);
165 assert_eq_const_safe!($T: _0.scatter_bits(B), 0);
166 assert_eq_const_safe!($T: _0.scatter_bits(C), 0);
167
168 assert_eq_const_safe!($T: A.scatter_bits(_1), A);
169 assert_eq_const_safe!($T: B.scatter_bits(_1), B);
170 assert_eq_const_safe!($T: C.scatter_bits(_1), C);
171 assert_eq_const_safe!($T: _1.scatter_bits(A), A);
172 assert_eq_const_safe!($T: _1.scatter_bits(B), B);
173 assert_eq_const_safe!($T: _1.scatter_bits(C), C);
130 fn test_extract_bits() {
131 assert_eq_const_safe!($T: $T::extract_bits(0b1010_0101, 0b0000_0011), 0b_0001);
132 assert_eq_const_safe!($T: $T::extract_bits(0b1010_0101, 0b0000_0110), 0b_0010);
133 assert_eq_const_safe!($T: $T::extract_bits(0b1010_0101, 0b0000_1100), 0b_0001);
134 assert_eq_const_safe!($T: $T::extract_bits(0b1010_0101, 0b0001_1000), 0b_0000);
135 assert_eq_const_safe!($T: $T::extract_bits(0b1010_0101, 0b0011_0000), 0b_0010);
136 assert_eq_const_safe!($T: $T::extract_bits(0b1010_0101, 0b0110_0000), 0b_0001);
137 assert_eq_const_safe!($T: $T::extract_bits(0b1010_0101, 0b1100_0000), 0b_0010);
138
139 assert_eq_const_safe!($T: A.extract_bits(_0), 0);
140 assert_eq_const_safe!($T: B.extract_bits(_0), 0);
141 assert_eq_const_safe!($T: C.extract_bits(_0), 0);
142 assert_eq_const_safe!($T: _0.extract_bits(A), 0);
143 assert_eq_const_safe!($T: _0.extract_bits(B), 0);
144 assert_eq_const_safe!($T: _0.extract_bits(C), 0);
145
146 assert_eq_const_safe!($T: A.extract_bits(_1), A);
147 assert_eq_const_safe!($T: B.extract_bits(_1), B);
148 assert_eq_const_safe!($T: C.extract_bits(_1), C);
149 assert_eq_const_safe!($T: _1.extract_bits(0b0010_0001), 0b0000_0011);
150 assert_eq_const_safe!($T: _1.extract_bits(0b0010_1100), 0b0000_0111);
151 assert_eq_const_safe!($T: _1.extract_bits(0b0111_1001), 0b0001_1111);
152 }
153
154 fn test_deposit_bits() {
155 assert_eq_const_safe!($T: $T::deposit_bits(0b1111, 0b1001_0110), 0b1001_0110);
156 assert_eq_const_safe!($T: $T::deposit_bits(0b0001, 0b1001_0110), 0b0000_0010);
157 assert_eq_const_safe!($T: $T::deposit_bits(0b0010, 0b1001_0110), 0b0000_0100);
158 assert_eq_const_safe!($T: $T::deposit_bits(0b0100, 0b1001_0110), 0b0001_0000);
159 assert_eq_const_safe!($T: $T::deposit_bits(0b1000, 0b1001_0110), 0b1000_0000);
160
161 assert_eq_const_safe!($T: A.deposit_bits(_0), 0);
162 assert_eq_const_safe!($T: B.deposit_bits(_0), 0);
163 assert_eq_const_safe!($T: C.deposit_bits(_0), 0);
164 assert_eq_const_safe!($T: _0.deposit_bits(A), 0);
165 assert_eq_const_safe!($T: _0.deposit_bits(B), 0);
166 assert_eq_const_safe!($T: _0.deposit_bits(C), 0);
167
168 assert_eq_const_safe!($T: A.deposit_bits(_1), A);
169 assert_eq_const_safe!($T: B.deposit_bits(_1), B);
170 assert_eq_const_safe!($T: C.deposit_bits(_1), C);
171 assert_eq_const_safe!($T: _1.deposit_bits(A), A);
172 assert_eq_const_safe!($T: _1.deposit_bits(B), B);
173 assert_eq_const_safe!($T: _1.deposit_bits(C), C);
174174 }
175175
176176 fn test_reverse_bits() {
......@@ -389,7 +389,7 @@ macro_rules! uint_module {
389389
390390 #[cfg(not(miri))] // Miri is too slow
391391 #[test]
392 fn test_lots_of_gather_scatter() {
392 fn test_lots_of_extract_deposit() {
393393 // Generate a handful of bit patterns to use as inputs
394394 let xs = {
395395 let mut xs = vec![];
......@@ -414,7 +414,7 @@ macro_rules! uint_module {
414414
415415 for sparse in sparse_masks {
416416 // Collect the set bits to sequential low bits
417 let dense = sparse.gather_bits(sparse);
417 let dense = sparse.extract_bits(sparse);
418418 let count = sparse.count_ones();
419419 assert_eq!(count, dense.count_ones());
420420 assert_eq!(count, dense.trailing_ones());
......@@ -424,27 +424,27 @@ macro_rules! uint_module {
424424 let mut bit = 1 as $T;
425425 for _ in 0..count {
426426 let lowest_one = t.isolate_lowest_one();
427 assert_eq!(lowest_one, bit.scatter_bits(sparse));
428 assert_eq!(bit, lowest_one.gather_bits(sparse));
427 assert_eq!(lowest_one, bit.deposit_bits(sparse));
428 assert_eq!(bit, lowest_one.extract_bits(sparse));
429429 t ^= lowest_one;
430430 bit <<= 1;
431431 }
432432 // Other bits are ignored
433 assert_eq!(0, bit.wrapping_neg().scatter_bits(sparse));
434 assert_eq!(0, (!sparse).gather_bits(sparse));
433 assert_eq!(0, bit.wrapping_neg().deposit_bits(sparse));
434 assert_eq!(0, (!sparse).extract_bits(sparse));
435435
436436 for &x in &xs {
437437 // Gather bits from `x & sparse` to `dense`
438 let dx = x.gather_bits(sparse);
438 let dx = x.extract_bits(sparse);
439439 assert_eq!(dx & !dense, 0);
440440
441441 // Scatter bits from `x & dense` to `sparse`
442 let sx = x.scatter_bits(sparse);
442 let sx = x.deposit_bits(sparse);
443443 assert_eq!(sx & !sparse, 0);
444444
445445 // The other recovers the input (within the mask)
446 assert_eq!(dx.scatter_bits(sparse), x & sparse);
447 assert_eq!(sx.gather_bits(sparse), x & dense);
446 assert_eq!(dx.deposit_bits(sparse), x & sparse);
447 assert_eq!(sx.extract_bits(sparse), x & dense);
448448 }
449449 }
450450 }
library/std/Cargo.toml+3-3
......@@ -55,8 +55,8 @@ object = { version = "0.37.1", default-features = false, optional = true, featur
5555 'archive',
5656] }
5757
58[target.'cfg(any(windows, target_os = "cygwin"))'.dependencies.windows-targets]
59path = "../windows_targets"
58[target.'cfg(any(windows, target_os = "cygwin"))'.dependencies.windows-link]
59path = "../windows_link"
6060
6161[dev-dependencies]
6262rand = { version = "0.9.0", default-features = false, features = ["alloc"] }
......@@ -130,7 +130,7 @@ llvm_enzyme = ["core/llvm_enzyme"]
130130
131131# Enable using raw-dylib for Windows imports.
132132# This will eventually be the default.
133windows_raw_dylib = ["windows-targets/windows_raw_dylib"]
133windows_raw_dylib = ["windows-link/windows_raw_dylib"]
134134
135135[package.metadata.fortanix-sgx]
136136# Maximum possible number of threads when testing
library/std/src/hash/random.rs-4
......@@ -7,7 +7,6 @@
77//!
88//! [`collections`]: crate::collections
99
10#[allow(deprecated)]
1110use super::{BuildHasher, Hasher, SipHasher13};
1211use crate::cell::Cell;
1312use crate::fmt;
......@@ -81,7 +80,6 @@ impl RandomState {
8180impl BuildHasher for RandomState {
8281 type Hasher = DefaultHasher;
8382 #[inline]
84 #[allow(deprecated)]
8583 fn build_hasher(&self) -> DefaultHasher {
8684 DefaultHasher(SipHasher13::new_with_keys(self.k0, self.k1))
8785 }
......@@ -91,7 +89,6 @@ impl BuildHasher for RandomState {
9189///
9290/// The internal algorithm is not specified, and so it and its hashes should
9391/// not be relied upon over releases.
94#[allow(deprecated)]
9592#[derive(Clone, Debug)]
9693#[stable(feature = "hashmap_build_hasher", since = "1.7.0")]
9794pub struct DefaultHasher(SipHasher13);
......@@ -104,7 +101,6 @@ impl DefaultHasher {
104101 /// instances created through `new` or `default`.
105102 #[stable(feature = "hashmap_default_hasher", since = "1.13.0")]
106103 #[inline]
107 #[allow(deprecated)]
108104 #[rustc_const_unstable(feature = "const_default", issue = "143894")]
109105 #[must_use]
110106 pub const fn new() -> DefaultHasher {
library/std/src/sys/alloc/windows.rs+4-4
......@@ -20,7 +20,7 @@ const HEAP_ZERO_MEMORY: u32 = 0x00000008;
2020// always return the same handle, which remains valid for the entire lifetime of the process.
2121//
2222// See https://docs.microsoft.com/windows/win32/api/heapapi/nf-heapapi-getprocessheap
23windows_targets::link!("kernel32.dll" "system" fn GetProcessHeap() -> c::HANDLE);
23windows_link::link!("kernel32.dll" "system" fn GetProcessHeap() -> c::HANDLE);
2424
2525// Allocate a block of `dwBytes` bytes of memory from a given heap `hHeap`.
2626// The allocated memory may be uninitialized, or zeroed if `dwFlags` is
......@@ -36,7 +36,7 @@ windows_targets::link!("kernel32.dll" "system" fn GetProcessHeap() -> c::HANDLE)
3636// Note that `dwBytes` is allowed to be zero, contrary to some other allocators.
3737//
3838// See https://docs.microsoft.com/windows/win32/api/heapapi/nf-heapapi-heapalloc
39windows_targets::link!("kernel32.dll" "system" fn HeapAlloc(hheap: c::HANDLE, dwflags: u32, dwbytes: usize) -> *mut c_void);
39windows_link::link!("kernel32.dll" "system" fn HeapAlloc(hheap: c::HANDLE, dwflags: u32, dwbytes: usize) -> *mut c_void);
4040
4141// Reallocate a block of memory behind a given pointer `lpMem` from a given heap `hHeap`,
4242// to a block of at least `dwBytes` bytes, either shrinking the block in place,
......@@ -57,7 +57,7 @@ windows_targets::link!("kernel32.dll" "system" fn HeapAlloc(hheap: c::HANDLE, dw
5757// Note that `dwBytes` is allowed to be zero, contrary to some other allocators.
5858//
5959// See https://docs.microsoft.com/windows/win32/api/heapapi/nf-heapapi-heaprealloc
60windows_targets::link!("kernel32.dll" "system" fn HeapReAlloc(
60windows_link::link!("kernel32.dll" "system" fn HeapReAlloc(
6161 hheap: c::HANDLE,
6262 dwflags : u32,
6363 lpmem: *const c_void,
......@@ -78,7 +78,7 @@ windows_targets::link!("kernel32.dll" "system" fn HeapReAlloc(
7878// Note that `lpMem` is allowed to be null, which will not cause the operation to fail.
7979//
8080// See https://docs.microsoft.com/windows/win32/api/heapapi/nf-heapapi-heapfree
81windows_targets::link!("kernel32.dll" "system" fn HeapFree(hheap: c::HANDLE, dwflags: u32, lpmem: *const c_void) -> c::BOOL);
81windows_link::link!("kernel32.dll" "system" fn HeapFree(hheap: c::HANDLE, dwflags: u32, lpmem: *const c_void) -> c::BOOL);
8282
8383fn get_process_heap() -> *mut c_void {
8484 // SAFETY: GetProcessHeap simply returns a valid handle or NULL so is always safe to call.
library/std/src/sys/pal/windows/c.rs+7-7
......@@ -109,7 +109,7 @@ unsafe extern "system" {
109109 pub fn ProcessPrng(pbdata: *mut u8, cbdata: usize) -> BOOL;
110110}
111111
112windows_targets::link!("ntdll.dll" "system" fn NtCreateNamedPipeFile(
112windows_link::link!("ntdll.dll" "system" fn NtCreateNamedPipeFile(
113113 filehandle: *mut HANDLE,
114114 desiredaccess: FILE_ACCESS_RIGHTS,
115115 objectattributes: *const OBJECT_ATTRIBUTES,
......@@ -229,15 +229,15 @@ compat_fn_with_fallback! {
229229
230230cfg_select! {
231231 target_vendor = "uwp" => {
232 windows_targets::link_raw_dylib!("ntdll.dll" "system" fn NtCreateFile(filehandle : *mut HANDLE, desiredaccess : FILE_ACCESS_RIGHTS, objectattributes : *const OBJECT_ATTRIBUTES, iostatusblock : *mut IO_STATUS_BLOCK, allocationsize : *const i64, fileattributes : FILE_FLAGS_AND_ATTRIBUTES, shareaccess : FILE_SHARE_MODE, createdisposition : NTCREATEFILE_CREATE_DISPOSITION, createoptions : NTCREATEFILE_CREATE_OPTIONS, eabuffer : *const core::ffi::c_void, ealength : u32) -> NTSTATUS);
233 windows_targets::link_raw_dylib!("ntdll.dll" "system" fn NtOpenFile(filehandle : *mut HANDLE, desiredaccess : u32, objectattributes : *const OBJECT_ATTRIBUTES, iostatusblock : *mut IO_STATUS_BLOCK, shareaccess : u32, openoptions : u32) -> NTSTATUS);
234 windows_targets::link_raw_dylib!("ntdll.dll" "system" fn NtReadFile(filehandle : HANDLE, event : HANDLE, apcroutine : PIO_APC_ROUTINE, apccontext : *const core::ffi::c_void, iostatusblock : *mut IO_STATUS_BLOCK, buffer : *mut core::ffi::c_void, length : u32, byteoffset : *const i64, key : *const u32) -> NTSTATUS);
235 windows_targets::link_raw_dylib!("ntdll.dll" "system" fn NtWriteFile(filehandle : HANDLE, event : HANDLE, apcroutine : PIO_APC_ROUTINE, apccontext : *const core::ffi::c_void, iostatusblock : *mut IO_STATUS_BLOCK, buffer : *const core::ffi::c_void, length : u32, byteoffset : *const i64, key : *const u32) -> NTSTATUS);
236 windows_targets::link_raw_dylib!("ntdll.dll" "system" fn RtlNtStatusToDosError(status : NTSTATUS) -> u32);
232 windows_link::link_raw_dylib!("ntdll.dll" "system" fn NtCreateFile(filehandle : *mut HANDLE, desiredaccess : FILE_ACCESS_RIGHTS, objectattributes : *const OBJECT_ATTRIBUTES, iostatusblock : *mut IO_STATUS_BLOCK, allocationsize : *const i64, fileattributes : FILE_FLAGS_AND_ATTRIBUTES, shareaccess : FILE_SHARE_MODE, createdisposition : NTCREATEFILE_CREATE_DISPOSITION, createoptions : NTCREATEFILE_CREATE_OPTIONS, eabuffer : *const core::ffi::c_void, ealength : u32) -> NTSTATUS);
233 windows_link::link_raw_dylib!("ntdll.dll" "system" fn NtOpenFile(filehandle : *mut HANDLE, desiredaccess : u32, objectattributes : *const OBJECT_ATTRIBUTES, iostatusblock : *mut IO_STATUS_BLOCK, shareaccess : u32, openoptions : u32) -> NTSTATUS);
234 windows_link::link_raw_dylib!("ntdll.dll" "system" fn NtReadFile(filehandle : HANDLE, event : HANDLE, apcroutine : PIO_APC_ROUTINE, apccontext : *const core::ffi::c_void, iostatusblock : *mut IO_STATUS_BLOCK, buffer : *mut core::ffi::c_void, length : u32, byteoffset : *const i64, key : *const u32) -> NTSTATUS);
235 windows_link::link_raw_dylib!("ntdll.dll" "system" fn NtWriteFile(filehandle : HANDLE, event : HANDLE, apcroutine : PIO_APC_ROUTINE, apccontext : *const core::ffi::c_void, iostatusblock : *mut IO_STATUS_BLOCK, buffer : *const core::ffi::c_void, length : u32, byteoffset : *const i64, key : *const u32) -> NTSTATUS);
236 windows_link::link_raw_dylib!("ntdll.dll" "system" fn RtlNtStatusToDosError(status : NTSTATUS) -> u32);
237237 }
238238 _ => {}
239239}
240240
241241// Only available starting with Windows 8.
242242#[cfg(not(target_vendor = "win7"))]
243windows_targets::link!("ws2_32.dll" "system" fn GetHostNameW(name : PWSTR, namelen : i32) -> i32);
243windows_link::link!("ws2_32.dll" "system" fn GetHostNameW(name : PWSTR, namelen : i32) -> i32);
library/std/src/sys/pal/windows/c/bindings.txt+1-1
......@@ -2,7 +2,7 @@
22--flat
33--sys
44--no-deps
5--link windows_targets
5--link windows_link
66--filter
77!INVALID_HANDLE_VALUE
88ABOVE_NORMAL_PRIORITY_CLASS
library/std/src/sys/pal/windows/c/windows_sys.rs+141-141
......@@ -1,147 +1,147 @@
1// Bindings generated by `windows-bindgen` 0.61.1
1// Bindings generated by `windows-bindgen` 0.66.0
22
33#![allow(non_snake_case, non_upper_case_globals, non_camel_case_types, dead_code, clippy::all)]
44
5windows_targets::link!("kernel32.dll" "system" fn AcquireSRWLockExclusive(srwlock : *mut SRWLOCK));
6windows_targets::link!("kernel32.dll" "system" fn AcquireSRWLockShared(srwlock : *mut SRWLOCK));
7windows_targets::link!("kernel32.dll" "system" fn AddVectoredExceptionHandler(first : u32, handler : PVECTORED_EXCEPTION_HANDLER) -> *mut core::ffi::c_void);
8windows_targets::link!("kernel32.dll" "system" fn CancelIo(hfile : HANDLE) -> BOOL);
9windows_targets::link!("kernel32.dll" "system" fn CloseHandle(hobject : HANDLE) -> BOOL);
10windows_targets::link!("kernel32.dll" "system" fn CompareStringOrdinal(lpstring1 : PCWSTR, cchcount1 : i32, lpstring2 : PCWSTR, cchcount2 : i32, bignorecase : BOOL) -> COMPARESTRING_RESULT);
11windows_targets::link!("kernel32.dll" "system" fn CopyFileExW(lpexistingfilename : PCWSTR, lpnewfilename : PCWSTR, lpprogressroutine : LPPROGRESS_ROUTINE, lpdata : *const core::ffi::c_void, pbcancel : *mut BOOL, dwcopyflags : COPYFILE_FLAGS) -> BOOL);
12windows_targets::link!("kernel32.dll" "system" fn CreateDirectoryW(lppathname : PCWSTR, lpsecurityattributes : *const SECURITY_ATTRIBUTES) -> BOOL);
13windows_targets::link!("kernel32.dll" "system" fn CreateEventW(lpeventattributes : *const SECURITY_ATTRIBUTES, bmanualreset : BOOL, binitialstate : BOOL, lpname : PCWSTR) -> HANDLE);
14windows_targets::link!("kernel32.dll" "system" fn CreateFileW(lpfilename : PCWSTR, dwdesiredaccess : u32, dwsharemode : FILE_SHARE_MODE, lpsecurityattributes : *const SECURITY_ATTRIBUTES, dwcreationdisposition : FILE_CREATION_DISPOSITION, dwflagsandattributes : FILE_FLAGS_AND_ATTRIBUTES, htemplatefile : HANDLE) -> HANDLE);
15windows_targets::link!("kernel32.dll" "system" fn CreateHardLinkW(lpfilename : PCWSTR, lpexistingfilename : PCWSTR, lpsecurityattributes : *const SECURITY_ATTRIBUTES) -> BOOL);
16windows_targets::link!("kernel32.dll" "system" fn CreateNamedPipeW(lpname : PCWSTR, dwopenmode : FILE_FLAGS_AND_ATTRIBUTES, dwpipemode : NAMED_PIPE_MODE, nmaxinstances : u32, noutbuffersize : u32, ninbuffersize : u32, ndefaulttimeout : u32, lpsecurityattributes : *const SECURITY_ATTRIBUTES) -> HANDLE);
17windows_targets::link!("kernel32.dll" "system" fn CreatePipe(hreadpipe : *mut HANDLE, hwritepipe : *mut HANDLE, lppipeattributes : *const SECURITY_ATTRIBUTES, nsize : u32) -> BOOL);
18windows_targets::link!("kernel32.dll" "system" fn CreateProcessW(lpapplicationname : PCWSTR, lpcommandline : PWSTR, lpprocessattributes : *const SECURITY_ATTRIBUTES, lpthreadattributes : *const SECURITY_ATTRIBUTES, binherithandles : BOOL, dwcreationflags : PROCESS_CREATION_FLAGS, lpenvironment : *const core::ffi::c_void, lpcurrentdirectory : PCWSTR, lpstartupinfo : *const STARTUPINFOW, lpprocessinformation : *mut PROCESS_INFORMATION) -> BOOL);
19windows_targets::link!("kernel32.dll" "system" fn CreateSymbolicLinkW(lpsymlinkfilename : PCWSTR, lptargetfilename : PCWSTR, dwflags : SYMBOLIC_LINK_FLAGS) -> bool);
20windows_targets::link!("kernel32.dll" "system" fn CreateThread(lpthreadattributes : *const SECURITY_ATTRIBUTES, dwstacksize : usize, lpstartaddress : LPTHREAD_START_ROUTINE, lpparameter : *const core::ffi::c_void, dwcreationflags : THREAD_CREATION_FLAGS, lpthreadid : *mut u32) -> HANDLE);
21windows_targets::link!("kernel32.dll" "system" fn CreateWaitableTimerExW(lptimerattributes : *const SECURITY_ATTRIBUTES, lptimername : PCWSTR, dwflags : u32, dwdesiredaccess : u32) -> HANDLE);
22windows_targets::link!("kernel32.dll" "system" fn DeleteFileW(lpfilename : PCWSTR) -> BOOL);
23windows_targets::link!("kernel32.dll" "system" fn DeleteProcThreadAttributeList(lpattributelist : LPPROC_THREAD_ATTRIBUTE_LIST));
24windows_targets::link!("kernel32.dll" "system" fn DeviceIoControl(hdevice : HANDLE, dwiocontrolcode : u32, lpinbuffer : *const core::ffi::c_void, ninbuffersize : u32, lpoutbuffer : *mut core::ffi::c_void, noutbuffersize : u32, lpbytesreturned : *mut u32, lpoverlapped : *mut OVERLAPPED) -> BOOL);
25windows_targets::link!("kernel32.dll" "system" fn DuplicateHandle(hsourceprocesshandle : HANDLE, hsourcehandle : HANDLE, htargetprocesshandle : HANDLE, lptargethandle : *mut HANDLE, dwdesiredaccess : u32, binherithandle : BOOL, dwoptions : DUPLICATE_HANDLE_OPTIONS) -> BOOL);
26windows_targets::link!("kernel32.dll" "system" fn ExitProcess(uexitcode : u32) -> !);
27windows_targets::link!("kernel32.dll" "system" fn FindClose(hfindfile : HANDLE) -> BOOL);
28windows_targets::link!("kernel32.dll" "system" fn FindFirstFileExW(lpfilename : PCWSTR, finfolevelid : FINDEX_INFO_LEVELS, lpfindfiledata : *mut core::ffi::c_void, fsearchop : FINDEX_SEARCH_OPS, lpsearchfilter : *const core::ffi::c_void, dwadditionalflags : FIND_FIRST_EX_FLAGS) -> HANDLE);
29windows_targets::link!("kernel32.dll" "system" fn FindNextFileW(hfindfile : HANDLE, lpfindfiledata : *mut WIN32_FIND_DATAW) -> BOOL);
30windows_targets::link!("kernel32.dll" "system" fn FlushFileBuffers(hfile : HANDLE) -> BOOL);
31windows_targets::link!("kernel32.dll" "system" fn FormatMessageW(dwflags : FORMAT_MESSAGE_OPTIONS, lpsource : *const core::ffi::c_void, dwmessageid : u32, dwlanguageid : u32, lpbuffer : PWSTR, nsize : u32, arguments : *const *const i8) -> u32);
32windows_targets::link!("kernel32.dll" "system" fn FreeEnvironmentStringsW(penv : PCWSTR) -> BOOL);
33windows_targets::link!("kernel32.dll" "system" fn GetActiveProcessorCount(groupnumber : u16) -> u32);
34windows_targets::link!("kernel32.dll" "system" fn GetCommandLineW() -> PCWSTR);
35windows_targets::link!("kernel32.dll" "system" fn GetConsoleMode(hconsolehandle : HANDLE, lpmode : *mut CONSOLE_MODE) -> BOOL);
36windows_targets::link!("kernel32.dll" "system" fn GetConsoleOutputCP() -> u32);
37windows_targets::link!("kernel32.dll" "system" fn GetCurrentDirectoryW(nbufferlength : u32, lpbuffer : PWSTR) -> u32);
38windows_targets::link!("kernel32.dll" "system" fn GetCurrentProcess() -> HANDLE);
39windows_targets::link!("kernel32.dll" "system" fn GetCurrentProcessId() -> u32);
40windows_targets::link!("kernel32.dll" "system" fn GetCurrentThread() -> HANDLE);
41windows_targets::link!("kernel32.dll" "system" fn GetCurrentThreadId() -> u32);
42windows_targets::link!("kernel32.dll" "system" fn GetEnvironmentStringsW() -> PWSTR);
43windows_targets::link!("kernel32.dll" "system" fn GetEnvironmentVariableW(lpname : PCWSTR, lpbuffer : PWSTR, nsize : u32) -> u32);
44windows_targets::link!("kernel32.dll" "system" fn GetExitCodeProcess(hprocess : HANDLE, lpexitcode : *mut u32) -> BOOL);
45windows_targets::link!("kernel32.dll" "system" fn GetFileAttributesW(lpfilename : PCWSTR) -> u32);
46windows_targets::link!("kernel32.dll" "system" fn GetFileInformationByHandle(hfile : HANDLE, lpfileinformation : *mut BY_HANDLE_FILE_INFORMATION) -> BOOL);
47windows_targets::link!("kernel32.dll" "system" fn GetFileInformationByHandleEx(hfile : HANDLE, fileinformationclass : FILE_INFO_BY_HANDLE_CLASS, lpfileinformation : *mut core::ffi::c_void, dwbuffersize : u32) -> BOOL);
48windows_targets::link!("kernel32.dll" "system" fn GetFileSizeEx(hfile : HANDLE, lpfilesize : *mut i64) -> BOOL);
49windows_targets::link!("kernel32.dll" "system" fn GetFileType(hfile : HANDLE) -> FILE_TYPE);
50windows_targets::link!("kernel32.dll" "system" fn GetFinalPathNameByHandleW(hfile : HANDLE, lpszfilepath : PWSTR, cchfilepath : u32, dwflags : GETFINALPATHNAMEBYHANDLE_FLAGS) -> u32);
51windows_targets::link!("kernel32.dll" "system" fn GetFullPathNameW(lpfilename : PCWSTR, nbufferlength : u32, lpbuffer : PWSTR, lpfilepart : *mut PWSTR) -> u32);
52windows_targets::link!("kernel32.dll" "system" fn GetLastError() -> WIN32_ERROR);
53windows_targets::link!("kernel32.dll" "system" fn GetModuleFileNameW(hmodule : HMODULE, lpfilename : PWSTR, nsize : u32) -> u32);
54windows_targets::link!("kernel32.dll" "system" fn GetModuleHandleA(lpmodulename : PCSTR) -> HMODULE);
55windows_targets::link!("kernel32.dll" "system" fn GetModuleHandleW(lpmodulename : PCWSTR) -> HMODULE);
56windows_targets::link!("kernel32.dll" "system" fn GetOverlappedResult(hfile : HANDLE, lpoverlapped : *const OVERLAPPED, lpnumberofbytestransferred : *mut u32, bwait : BOOL) -> BOOL);
57windows_targets::link!("kernel32.dll" "system" fn GetProcAddress(hmodule : HMODULE, lpprocname : PCSTR) -> FARPROC);
58windows_targets::link!("kernel32.dll" "system" fn GetProcessId(process : HANDLE) -> u32);
59windows_targets::link!("kernel32.dll" "system" fn GetStdHandle(nstdhandle : STD_HANDLE) -> HANDLE);
60windows_targets::link!("kernel32.dll" "system" fn GetSystemDirectoryW(lpbuffer : PWSTR, usize : u32) -> u32);
61windows_targets::link!("kernel32.dll" "system" fn GetSystemInfo(lpsysteminfo : *mut SYSTEM_INFO));
62windows_targets::link!("kernel32.dll" "system" fn GetSystemTimeAsFileTime(lpsystemtimeasfiletime : *mut FILETIME));
63windows_targets::link!("kernel32.dll" "system" fn GetSystemTimePreciseAsFileTime(lpsystemtimeasfiletime : *mut FILETIME));
64windows_targets::link!("kernel32.dll" "system" fn GetTempPathW(nbufferlength : u32, lpbuffer : PWSTR) -> u32);
65windows_targets::link!("userenv.dll" "system" fn GetUserProfileDirectoryW(htoken : HANDLE, lpprofiledir : PWSTR, lpcchsize : *mut u32) -> BOOL);
66windows_targets::link!("kernel32.dll" "system" fn GetWindowsDirectoryW(lpbuffer : PWSTR, usize : u32) -> u32);
67windows_targets::link!("kernel32.dll" "system" fn InitOnceBeginInitialize(lpinitonce : *mut INIT_ONCE, dwflags : u32, fpending : *mut BOOL, lpcontext : *mut *mut core::ffi::c_void) -> BOOL);
68windows_targets::link!("kernel32.dll" "system" fn InitOnceComplete(lpinitonce : *mut INIT_ONCE, dwflags : u32, lpcontext : *const core::ffi::c_void) -> BOOL);
69windows_targets::link!("kernel32.dll" "system" fn InitializeProcThreadAttributeList(lpattributelist : LPPROC_THREAD_ATTRIBUTE_LIST, dwattributecount : u32, dwflags : u32, lpsize : *mut usize) -> BOOL);
70windows_targets::link!("kernel32.dll" "system" fn LocalFree(hmem : HLOCAL) -> HLOCAL);
71windows_targets::link!("kernel32.dll" "system" fn LockFileEx(hfile : HANDLE, dwflags : LOCK_FILE_FLAGS, dwreserved : u32, nnumberofbytestolocklow : u32, nnumberofbytestolockhigh : u32, lpoverlapped : *mut OVERLAPPED) -> BOOL);
72windows_targets::link!("kernel32.dll" "system" fn MoveFileExW(lpexistingfilename : PCWSTR, lpnewfilename : PCWSTR, dwflags : MOVE_FILE_FLAGS) -> BOOL);
73windows_targets::link!("kernel32.dll" "system" fn MultiByteToWideChar(codepage : u32, dwflags : MULTI_BYTE_TO_WIDE_CHAR_FLAGS, lpmultibytestr : PCSTR, cbmultibyte : i32, lpwidecharstr : PWSTR, cchwidechar : i32) -> i32);
74windows_targets::link!("ntdll.dll" "system" fn NtCreateFile(filehandle : *mut HANDLE, desiredaccess : FILE_ACCESS_RIGHTS, objectattributes : *const OBJECT_ATTRIBUTES, iostatusblock : *mut IO_STATUS_BLOCK, allocationsize : *const i64, fileattributes : FILE_FLAGS_AND_ATTRIBUTES, shareaccess : FILE_SHARE_MODE, createdisposition : NTCREATEFILE_CREATE_DISPOSITION, createoptions : NTCREATEFILE_CREATE_OPTIONS, eabuffer : *const core::ffi::c_void, ealength : u32) -> NTSTATUS);
75windows_targets::link!("ntdll.dll" "system" fn NtOpenFile(filehandle : *mut HANDLE, desiredaccess : u32, objectattributes : *const OBJECT_ATTRIBUTES, iostatusblock : *mut IO_STATUS_BLOCK, shareaccess : u32, openoptions : u32) -> NTSTATUS);
76windows_targets::link!("ntdll.dll" "system" fn NtReadFile(filehandle : HANDLE, event : HANDLE, apcroutine : PIO_APC_ROUTINE, apccontext : *const core::ffi::c_void, iostatusblock : *mut IO_STATUS_BLOCK, buffer : *mut core::ffi::c_void, length : u32, byteoffset : *const i64, key : *const u32) -> NTSTATUS);
77windows_targets::link!("ntdll.dll" "system" fn NtWriteFile(filehandle : HANDLE, event : HANDLE, apcroutine : PIO_APC_ROUTINE, apccontext : *const core::ffi::c_void, iostatusblock : *mut IO_STATUS_BLOCK, buffer : *const core::ffi::c_void, length : u32, byteoffset : *const i64, key : *const u32) -> NTSTATUS);
78windows_targets::link!("advapi32.dll" "system" fn OpenProcessToken(processhandle : HANDLE, desiredaccess : TOKEN_ACCESS_MASK, tokenhandle : *mut HANDLE) -> BOOL);
79windows_targets::link!("kernel32.dll" "system" fn QueryPerformanceCounter(lpperformancecount : *mut i64) -> BOOL);
80windows_targets::link!("kernel32.dll" "system" fn QueryPerformanceFrequency(lpfrequency : *mut i64) -> BOOL);
81windows_targets::link!("kernel32.dll" "system" fn ReadConsoleW(hconsoleinput : HANDLE, lpbuffer : *mut core::ffi::c_void, nnumberofcharstoread : u32, lpnumberofcharsread : *mut u32, pinputcontrol : *const CONSOLE_READCONSOLE_CONTROL) -> BOOL);
82windows_targets::link!("kernel32.dll" "system" fn ReadFile(hfile : HANDLE, lpbuffer : *mut u8, nnumberofbytestoread : u32, lpnumberofbytesread : *mut u32, lpoverlapped : *mut OVERLAPPED) -> BOOL);
83windows_targets::link!("kernel32.dll" "system" fn ReadFileEx(hfile : HANDLE, lpbuffer : *mut u8, nnumberofbytestoread : u32, lpoverlapped : *mut OVERLAPPED, lpcompletionroutine : LPOVERLAPPED_COMPLETION_ROUTINE) -> BOOL);
84windows_targets::link!("kernel32.dll" "system" fn ReleaseSRWLockExclusive(srwlock : *mut SRWLOCK));
85windows_targets::link!("kernel32.dll" "system" fn ReleaseSRWLockShared(srwlock : *mut SRWLOCK));
86windows_targets::link!("kernel32.dll" "system" fn RemoveDirectoryW(lppathname : PCWSTR) -> BOOL);
87windows_targets::link!("advapi32.dll" "system" "SystemFunction036" fn RtlGenRandom(randombuffer : *mut core::ffi::c_void, randombufferlength : u32) -> bool);
88windows_targets::link!("ntdll.dll" "system" fn RtlNtStatusToDosError(status : NTSTATUS) -> u32);
89windows_targets::link!("kernel32.dll" "system" fn SetCurrentDirectoryW(lppathname : PCWSTR) -> BOOL);
90windows_targets::link!("kernel32.dll" "system" fn SetEnvironmentVariableW(lpname : PCWSTR, lpvalue : PCWSTR) -> BOOL);
91windows_targets::link!("kernel32.dll" "system" fn SetFileAttributesW(lpfilename : PCWSTR, dwfileattributes : FILE_FLAGS_AND_ATTRIBUTES) -> BOOL);
92windows_targets::link!("kernel32.dll" "system" fn SetFileInformationByHandle(hfile : HANDLE, fileinformationclass : FILE_INFO_BY_HANDLE_CLASS, lpfileinformation : *const core::ffi::c_void, dwbuffersize : u32) -> BOOL);
93windows_targets::link!("kernel32.dll" "system" fn SetFilePointerEx(hfile : HANDLE, lidistancetomove : i64, lpnewfilepointer : *mut i64, dwmovemethod : SET_FILE_POINTER_MOVE_METHOD) -> BOOL);
94windows_targets::link!("kernel32.dll" "system" fn SetFileTime(hfile : HANDLE, lpcreationtime : *const FILETIME, lplastaccesstime : *const FILETIME, lplastwritetime : *const FILETIME) -> BOOL);
95windows_targets::link!("kernel32.dll" "system" fn SetHandleInformation(hobject : HANDLE, dwmask : u32, dwflags : HANDLE_FLAGS) -> BOOL);
96windows_targets::link!("kernel32.dll" "system" fn SetLastError(dwerrcode : WIN32_ERROR));
97windows_targets::link!("kernel32.dll" "system" fn SetThreadStackGuarantee(stacksizeinbytes : *mut u32) -> BOOL);
98windows_targets::link!("kernel32.dll" "system" fn SetWaitableTimer(htimer : HANDLE, lpduetime : *const i64, lperiod : i32, pfncompletionroutine : PTIMERAPCROUTINE, lpargtocompletionroutine : *const core::ffi::c_void, fresume : BOOL) -> BOOL);
99windows_targets::link!("kernel32.dll" "system" fn Sleep(dwmilliseconds : u32));
100windows_targets::link!("kernel32.dll" "system" fn SleepConditionVariableSRW(conditionvariable : *mut CONDITION_VARIABLE, srwlock : *mut SRWLOCK, dwmilliseconds : u32, flags : u32) -> BOOL);
101windows_targets::link!("kernel32.dll" "system" fn SleepEx(dwmilliseconds : u32, balertable : BOOL) -> u32);
102windows_targets::link!("kernel32.dll" "system" fn SwitchToThread() -> BOOL);
103windows_targets::link!("kernel32.dll" "system" fn TerminateProcess(hprocess : HANDLE, uexitcode : u32) -> BOOL);
104windows_targets::link!("kernel32.dll" "system" fn TlsAlloc() -> u32);
105windows_targets::link!("kernel32.dll" "system" fn TlsFree(dwtlsindex : u32) -> BOOL);
106windows_targets::link!("kernel32.dll" "system" fn TlsGetValue(dwtlsindex : u32) -> *mut core::ffi::c_void);
107windows_targets::link!("kernel32.dll" "system" fn TlsSetValue(dwtlsindex : u32, lptlsvalue : *const core::ffi::c_void) -> BOOL);
108windows_targets::link!("kernel32.dll" "system" fn TryAcquireSRWLockExclusive(srwlock : *mut SRWLOCK) -> bool);
109windows_targets::link!("kernel32.dll" "system" fn TryAcquireSRWLockShared(srwlock : *mut SRWLOCK) -> bool);
110windows_targets::link!("kernel32.dll" "system" fn UnlockFile(hfile : HANDLE, dwfileoffsetlow : u32, dwfileoffsethigh : u32, nnumberofbytestounlocklow : u32, nnumberofbytestounlockhigh : u32) -> BOOL);
111windows_targets::link!("kernel32.dll" "system" fn UpdateProcThreadAttribute(lpattributelist : LPPROC_THREAD_ATTRIBUTE_LIST, dwflags : u32, attribute : usize, lpvalue : *const core::ffi::c_void, cbsize : usize, lppreviousvalue : *mut core::ffi::c_void, lpreturnsize : *const usize) -> BOOL);
112windows_targets::link!("ws2_32.dll" "system" fn WSACleanup() -> i32);
113windows_targets::link!("ws2_32.dll" "system" fn WSADuplicateSocketW(s : SOCKET, dwprocessid : u32, lpprotocolinfo : *mut WSAPROTOCOL_INFOW) -> i32);
114windows_targets::link!("ws2_32.dll" "system" fn WSAGetLastError() -> WSA_ERROR);
115windows_targets::link!("ws2_32.dll" "system" fn WSARecv(s : SOCKET, lpbuffers : *const WSABUF, dwbuffercount : u32, lpnumberofbytesrecvd : *mut u32, lpflags : *mut u32, lpoverlapped : *mut OVERLAPPED, lpcompletionroutine : LPWSAOVERLAPPED_COMPLETION_ROUTINE) -> i32);
116windows_targets::link!("ws2_32.dll" "system" fn WSASend(s : SOCKET, lpbuffers : *const WSABUF, dwbuffercount : u32, lpnumberofbytessent : *mut u32, dwflags : u32, lpoverlapped : *mut OVERLAPPED, lpcompletionroutine : LPWSAOVERLAPPED_COMPLETION_ROUTINE) -> i32);
117windows_targets::link!("ws2_32.dll" "system" fn WSASocketW(af : i32, r#type : i32, protocol : i32, lpprotocolinfo : *const WSAPROTOCOL_INFOW, g : u32, dwflags : u32) -> SOCKET);
118windows_targets::link!("ws2_32.dll" "system" fn WSAStartup(wversionrequested : u16, lpwsadata : *mut WSADATA) -> i32);
119windows_targets::link!("kernel32.dll" "system" fn WaitForMultipleObjects(ncount : u32, lphandles : *const HANDLE, bwaitall : BOOL, dwmilliseconds : u32) -> WAIT_EVENT);
120windows_targets::link!("kernel32.dll" "system" fn WaitForSingleObject(hhandle : HANDLE, dwmilliseconds : u32) -> WAIT_EVENT);
121windows_targets::link!("kernel32.dll" "system" fn WakeAllConditionVariable(conditionvariable : *mut CONDITION_VARIABLE));
122windows_targets::link!("kernel32.dll" "system" fn WakeConditionVariable(conditionvariable : *mut CONDITION_VARIABLE));
123windows_targets::link!("kernel32.dll" "system" fn WideCharToMultiByte(codepage : u32, dwflags : u32, lpwidecharstr : PCWSTR, cchwidechar : i32, lpmultibytestr : PSTR, cbmultibyte : i32, lpdefaultchar : PCSTR, lpuseddefaultchar : *mut BOOL) -> i32);
124windows_targets::link!("kernel32.dll" "system" fn WriteConsoleW(hconsoleoutput : HANDLE, lpbuffer : PCWSTR, nnumberofcharstowrite : u32, lpnumberofcharswritten : *mut u32, lpreserved : *const core::ffi::c_void) -> BOOL);
125windows_targets::link!("kernel32.dll" "system" fn WriteFileEx(hfile : HANDLE, lpbuffer : *const u8, nnumberofbytestowrite : u32, lpoverlapped : *mut OVERLAPPED, lpcompletionroutine : LPOVERLAPPED_COMPLETION_ROUTINE) -> BOOL);
126windows_targets::link!("ws2_32.dll" "system" fn accept(s : SOCKET, addr : *mut SOCKADDR, addrlen : *mut i32) -> SOCKET);
127windows_targets::link!("ws2_32.dll" "system" fn bind(s : SOCKET, name : *const SOCKADDR, namelen : i32) -> i32);
128windows_targets::link!("ws2_32.dll" "system" fn closesocket(s : SOCKET) -> i32);
129windows_targets::link!("ws2_32.dll" "system" fn connect(s : SOCKET, name : *const SOCKADDR, namelen : i32) -> i32);
130windows_targets::link!("ws2_32.dll" "system" fn freeaddrinfo(paddrinfo : *const ADDRINFOA));
131windows_targets::link!("ws2_32.dll" "system" fn getaddrinfo(pnodename : PCSTR, pservicename : PCSTR, phints : *const ADDRINFOA, ppresult : *mut *mut ADDRINFOA) -> i32);
132windows_targets::link!("ws2_32.dll" "system" fn getpeername(s : SOCKET, name : *mut SOCKADDR, namelen : *mut i32) -> i32);
133windows_targets::link!("ws2_32.dll" "system" fn getsockname(s : SOCKET, name : *mut SOCKADDR, namelen : *mut i32) -> i32);
134windows_targets::link!("ws2_32.dll" "system" fn getsockopt(s : SOCKET, level : i32, optname : i32, optval : PSTR, optlen : *mut i32) -> i32);
135windows_targets::link!("ws2_32.dll" "system" fn ioctlsocket(s : SOCKET, cmd : i32, argp : *mut u32) -> i32);
136windows_targets::link!("ws2_32.dll" "system" fn listen(s : SOCKET, backlog : i32) -> i32);
137windows_targets::link!("kernel32.dll" "system" fn lstrlenW(lpstring : PCWSTR) -> i32);
138windows_targets::link!("ws2_32.dll" "system" fn recv(s : SOCKET, buf : PSTR, len : i32, flags : SEND_RECV_FLAGS) -> i32);
139windows_targets::link!("ws2_32.dll" "system" fn recvfrom(s : SOCKET, buf : PSTR, len : i32, flags : i32, from : *mut SOCKADDR, fromlen : *mut i32) -> i32);
140windows_targets::link!("ws2_32.dll" "system" fn select(nfds : i32, readfds : *mut FD_SET, writefds : *mut FD_SET, exceptfds : *mut FD_SET, timeout : *const TIMEVAL) -> i32);
141windows_targets::link!("ws2_32.dll" "system" fn send(s : SOCKET, buf : PCSTR, len : i32, flags : SEND_RECV_FLAGS) -> i32);
142windows_targets::link!("ws2_32.dll" "system" fn sendto(s : SOCKET, buf : PCSTR, len : i32, flags : i32, to : *const SOCKADDR, tolen : i32) -> i32);
143windows_targets::link!("ws2_32.dll" "system" fn setsockopt(s : SOCKET, level : i32, optname : i32, optval : PCSTR, optlen : i32) -> i32);
144windows_targets::link!("ws2_32.dll" "system" fn shutdown(s : SOCKET, how : WINSOCK_SHUTDOWN_HOW) -> i32);
5windows_link::link!("kernel32.dll" "system" fn AcquireSRWLockExclusive(srwlock : *mut SRWLOCK));
6windows_link::link!("kernel32.dll" "system" fn AcquireSRWLockShared(srwlock : *mut SRWLOCK));
7windows_link::link!("kernel32.dll" "system" fn AddVectoredExceptionHandler(first : u32, handler : PVECTORED_EXCEPTION_HANDLER) -> *mut core::ffi::c_void);
8windows_link::link!("kernel32.dll" "system" fn CancelIo(hfile : HANDLE) -> BOOL);
9windows_link::link!("kernel32.dll" "system" fn CloseHandle(hobject : HANDLE) -> BOOL);
10windows_link::link!("kernel32.dll" "system" fn CompareStringOrdinal(lpstring1 : PCWSTR, cchcount1 : i32, lpstring2 : PCWSTR, cchcount2 : i32, bignorecase : BOOL) -> COMPARESTRING_RESULT);
11windows_link::link!("kernel32.dll" "system" fn CopyFileExW(lpexistingfilename : PCWSTR, lpnewfilename : PCWSTR, lpprogressroutine : LPPROGRESS_ROUTINE, lpdata : *const core::ffi::c_void, pbcancel : *mut BOOL, dwcopyflags : COPYFILE_FLAGS) -> BOOL);
12windows_link::link!("kernel32.dll" "system" fn CreateDirectoryW(lppathname : PCWSTR, lpsecurityattributes : *const SECURITY_ATTRIBUTES) -> BOOL);
13windows_link::link!("kernel32.dll" "system" fn CreateEventW(lpeventattributes : *const SECURITY_ATTRIBUTES, bmanualreset : BOOL, binitialstate : BOOL, lpname : PCWSTR) -> HANDLE);
14windows_link::link!("kernel32.dll" "system" fn CreateFileW(lpfilename : PCWSTR, dwdesiredaccess : u32, dwsharemode : FILE_SHARE_MODE, lpsecurityattributes : *const SECURITY_ATTRIBUTES, dwcreationdisposition : FILE_CREATION_DISPOSITION, dwflagsandattributes : FILE_FLAGS_AND_ATTRIBUTES, htemplatefile : HANDLE) -> HANDLE);
15windows_link::link!("kernel32.dll" "system" fn CreateHardLinkW(lpfilename : PCWSTR, lpexistingfilename : PCWSTR, lpsecurityattributes : *const SECURITY_ATTRIBUTES) -> BOOL);
16windows_link::link!("kernel32.dll" "system" fn CreateNamedPipeW(lpname : PCWSTR, dwopenmode : FILE_FLAGS_AND_ATTRIBUTES, dwpipemode : NAMED_PIPE_MODE, nmaxinstances : u32, noutbuffersize : u32, ninbuffersize : u32, ndefaulttimeout : u32, lpsecurityattributes : *const SECURITY_ATTRIBUTES) -> HANDLE);
17windows_link::link!("kernel32.dll" "system" fn CreatePipe(hreadpipe : *mut HANDLE, hwritepipe : *mut HANDLE, lppipeattributes : *const SECURITY_ATTRIBUTES, nsize : u32) -> BOOL);
18windows_link::link!("kernel32.dll" "system" fn CreateProcessW(lpapplicationname : PCWSTR, lpcommandline : PWSTR, lpprocessattributes : *const SECURITY_ATTRIBUTES, lpthreadattributes : *const SECURITY_ATTRIBUTES, binherithandles : BOOL, dwcreationflags : PROCESS_CREATION_FLAGS, lpenvironment : *const core::ffi::c_void, lpcurrentdirectory : PCWSTR, lpstartupinfo : *const STARTUPINFOW, lpprocessinformation : *mut PROCESS_INFORMATION) -> BOOL);
19windows_link::link!("kernel32.dll" "system" fn CreateSymbolicLinkW(lpsymlinkfilename : PCWSTR, lptargetfilename : PCWSTR, dwflags : SYMBOLIC_LINK_FLAGS) -> bool);
20windows_link::link!("kernel32.dll" "system" fn CreateThread(lpthreadattributes : *const SECURITY_ATTRIBUTES, dwstacksize : usize, lpstartaddress : LPTHREAD_START_ROUTINE, lpparameter : *const core::ffi::c_void, dwcreationflags : THREAD_CREATION_FLAGS, lpthreadid : *mut u32) -> HANDLE);
21windows_link::link!("kernel32.dll" "system" fn CreateWaitableTimerExW(lptimerattributes : *const SECURITY_ATTRIBUTES, lptimername : PCWSTR, dwflags : u32, dwdesiredaccess : u32) -> HANDLE);
22windows_link::link!("kernel32.dll" "system" fn DeleteFileW(lpfilename : PCWSTR) -> BOOL);
23windows_link::link!("kernel32.dll" "system" fn DeleteProcThreadAttributeList(lpattributelist : LPPROC_THREAD_ATTRIBUTE_LIST));
24windows_link::link!("kernel32.dll" "system" fn DeviceIoControl(hdevice : HANDLE, dwiocontrolcode : u32, lpinbuffer : *const core::ffi::c_void, ninbuffersize : u32, lpoutbuffer : *mut core::ffi::c_void, noutbuffersize : u32, lpbytesreturned : *mut u32, lpoverlapped : *mut OVERLAPPED) -> BOOL);
25windows_link::link!("kernel32.dll" "system" fn DuplicateHandle(hsourceprocesshandle : HANDLE, hsourcehandle : HANDLE, htargetprocesshandle : HANDLE, lptargethandle : *mut HANDLE, dwdesiredaccess : u32, binherithandle : BOOL, dwoptions : DUPLICATE_HANDLE_OPTIONS) -> BOOL);
26windows_link::link!("kernel32.dll" "system" fn ExitProcess(uexitcode : u32) -> !);
27windows_link::link!("kernel32.dll" "system" fn FindClose(hfindfile : HANDLE) -> BOOL);
28windows_link::link!("kernel32.dll" "system" fn FindFirstFileExW(lpfilename : PCWSTR, finfolevelid : FINDEX_INFO_LEVELS, lpfindfiledata : *mut core::ffi::c_void, fsearchop : FINDEX_SEARCH_OPS, lpsearchfilter : *const core::ffi::c_void, dwadditionalflags : FIND_FIRST_EX_FLAGS) -> HANDLE);
29windows_link::link!("kernel32.dll" "system" fn FindNextFileW(hfindfile : HANDLE, lpfindfiledata : *mut WIN32_FIND_DATAW) -> BOOL);
30windows_link::link!("kernel32.dll" "system" fn FlushFileBuffers(hfile : HANDLE) -> BOOL);
31windows_link::link!("kernel32.dll" "system" fn FormatMessageW(dwflags : FORMAT_MESSAGE_OPTIONS, lpsource : *const core::ffi::c_void, dwmessageid : u32, dwlanguageid : u32, lpbuffer : PWSTR, nsize : u32, arguments : *const *const i8) -> u32);
32windows_link::link!("kernel32.dll" "system" fn FreeEnvironmentStringsW(penv : PCWSTR) -> BOOL);
33windows_link::link!("kernel32.dll" "system" fn GetActiveProcessorCount(groupnumber : u16) -> u32);
34windows_link::link!("kernel32.dll" "system" fn GetCommandLineW() -> PCWSTR);
35windows_link::link!("kernel32.dll" "system" fn GetConsoleMode(hconsolehandle : HANDLE, lpmode : *mut CONSOLE_MODE) -> BOOL);
36windows_link::link!("kernel32.dll" "system" fn GetConsoleOutputCP() -> u32);
37windows_link::link!("kernel32.dll" "system" fn GetCurrentDirectoryW(nbufferlength : u32, lpbuffer : PWSTR) -> u32);
38windows_link::link!("kernel32.dll" "system" fn GetCurrentProcess() -> HANDLE);
39windows_link::link!("kernel32.dll" "system" fn GetCurrentProcessId() -> u32);
40windows_link::link!("kernel32.dll" "system" fn GetCurrentThread() -> HANDLE);
41windows_link::link!("kernel32.dll" "system" fn GetCurrentThreadId() -> u32);
42windows_link::link!("kernel32.dll" "system" fn GetEnvironmentStringsW() -> PWSTR);
43windows_link::link!("kernel32.dll" "system" fn GetEnvironmentVariableW(lpname : PCWSTR, lpbuffer : PWSTR, nsize : u32) -> u32);
44windows_link::link!("kernel32.dll" "system" fn GetExitCodeProcess(hprocess : HANDLE, lpexitcode : *mut u32) -> BOOL);
45windows_link::link!("kernel32.dll" "system" fn GetFileAttributesW(lpfilename : PCWSTR) -> u32);
46windows_link::link!("kernel32.dll" "system" fn GetFileInformationByHandle(hfile : HANDLE, lpfileinformation : *mut BY_HANDLE_FILE_INFORMATION) -> BOOL);
47windows_link::link!("kernel32.dll" "system" fn GetFileInformationByHandleEx(hfile : HANDLE, fileinformationclass : FILE_INFO_BY_HANDLE_CLASS, lpfileinformation : *mut core::ffi::c_void, dwbuffersize : u32) -> BOOL);
48windows_link::link!("kernel32.dll" "system" fn GetFileSizeEx(hfile : HANDLE, lpfilesize : *mut i64) -> BOOL);
49windows_link::link!("kernel32.dll" "system" fn GetFileType(hfile : HANDLE) -> FILE_TYPE);
50windows_link::link!("kernel32.dll" "system" fn GetFinalPathNameByHandleW(hfile : HANDLE, lpszfilepath : PWSTR, cchfilepath : u32, dwflags : GETFINALPATHNAMEBYHANDLE_FLAGS) -> u32);
51windows_link::link!("kernel32.dll" "system" fn GetFullPathNameW(lpfilename : PCWSTR, nbufferlength : u32, lpbuffer : PWSTR, lpfilepart : *mut PWSTR) -> u32);
52windows_link::link!("kernel32.dll" "system" fn GetLastError() -> WIN32_ERROR);
53windows_link::link!("kernel32.dll" "system" fn GetModuleFileNameW(hmodule : HMODULE, lpfilename : PWSTR, nsize : u32) -> u32);
54windows_link::link!("kernel32.dll" "system" fn GetModuleHandleA(lpmodulename : PCSTR) -> HMODULE);
55windows_link::link!("kernel32.dll" "system" fn GetModuleHandleW(lpmodulename : PCWSTR) -> HMODULE);
56windows_link::link!("kernel32.dll" "system" fn GetOverlappedResult(hfile : HANDLE, lpoverlapped : *const OVERLAPPED, lpnumberofbytestransferred : *mut u32, bwait : BOOL) -> BOOL);
57windows_link::link!("kernel32.dll" "system" fn GetProcAddress(hmodule : HMODULE, lpprocname : PCSTR) -> FARPROC);
58windows_link::link!("kernel32.dll" "system" fn GetProcessId(process : HANDLE) -> u32);
59windows_link::link!("kernel32.dll" "system" fn GetStdHandle(nstdhandle : STD_HANDLE) -> HANDLE);
60windows_link::link!("kernel32.dll" "system" fn GetSystemDirectoryW(lpbuffer : PWSTR, usize : u32) -> u32);
61windows_link::link!("kernel32.dll" "system" fn GetSystemInfo(lpsysteminfo : *mut SYSTEM_INFO));
62windows_link::link!("kernel32.dll" "system" fn GetSystemTimeAsFileTime(lpsystemtimeasfiletime : *mut FILETIME));
63windows_link::link!("kernel32.dll" "system" fn GetSystemTimePreciseAsFileTime(lpsystemtimeasfiletime : *mut FILETIME));
64windows_link::link!("kernel32.dll" "system" fn GetTempPathW(nbufferlength : u32, lpbuffer : PWSTR) -> u32);
65windows_link::link!("userenv.dll" "system" fn GetUserProfileDirectoryW(htoken : HANDLE, lpprofiledir : PWSTR, lpcchsize : *mut u32) -> BOOL);
66windows_link::link!("kernel32.dll" "system" fn GetWindowsDirectoryW(lpbuffer : PWSTR, usize : u32) -> u32);
67windows_link::link!("kernel32.dll" "system" fn InitOnceBeginInitialize(lpinitonce : *mut INIT_ONCE, dwflags : u32, fpending : *mut BOOL, lpcontext : *mut *mut core::ffi::c_void) -> BOOL);
68windows_link::link!("kernel32.dll" "system" fn InitOnceComplete(lpinitonce : *mut INIT_ONCE, dwflags : u32, lpcontext : *const core::ffi::c_void) -> BOOL);
69windows_link::link!("kernel32.dll" "system" fn InitializeProcThreadAttributeList(lpattributelist : LPPROC_THREAD_ATTRIBUTE_LIST, dwattributecount : u32, dwflags : u32, lpsize : *mut usize) -> BOOL);
70windows_link::link!("kernel32.dll" "system" fn LocalFree(hmem : HLOCAL) -> HLOCAL);
71windows_link::link!("kernel32.dll" "system" fn LockFileEx(hfile : HANDLE, dwflags : LOCK_FILE_FLAGS, dwreserved : u32, nnumberofbytestolocklow : u32, nnumberofbytestolockhigh : u32, lpoverlapped : *mut OVERLAPPED) -> BOOL);
72windows_link::link!("kernel32.dll" "system" fn MoveFileExW(lpexistingfilename : PCWSTR, lpnewfilename : PCWSTR, dwflags : MOVE_FILE_FLAGS) -> BOOL);
73windows_link::link!("kernel32.dll" "system" fn MultiByteToWideChar(codepage : u32, dwflags : MULTI_BYTE_TO_WIDE_CHAR_FLAGS, lpmultibytestr : PCSTR, cbmultibyte : i32, lpwidecharstr : PWSTR, cchwidechar : i32) -> i32);
74windows_link::link!("ntdll.dll" "system" fn NtCreateFile(filehandle : *mut HANDLE, desiredaccess : FILE_ACCESS_RIGHTS, objectattributes : *const OBJECT_ATTRIBUTES, iostatusblock : *mut IO_STATUS_BLOCK, allocationsize : *const i64, fileattributes : FILE_FLAGS_AND_ATTRIBUTES, shareaccess : FILE_SHARE_MODE, createdisposition : NTCREATEFILE_CREATE_DISPOSITION, createoptions : NTCREATEFILE_CREATE_OPTIONS, eabuffer : *const core::ffi::c_void, ealength : u32) -> NTSTATUS);
75windows_link::link!("ntdll.dll" "system" fn NtOpenFile(filehandle : *mut HANDLE, desiredaccess : u32, objectattributes : *const OBJECT_ATTRIBUTES, iostatusblock : *mut IO_STATUS_BLOCK, shareaccess : u32, openoptions : u32) -> NTSTATUS);
76windows_link::link!("ntdll.dll" "system" fn NtReadFile(filehandle : HANDLE, event : HANDLE, apcroutine : PIO_APC_ROUTINE, apccontext : *const core::ffi::c_void, iostatusblock : *mut IO_STATUS_BLOCK, buffer : *mut core::ffi::c_void, length : u32, byteoffset : *const i64, key : *const u32) -> NTSTATUS);
77windows_link::link!("ntdll.dll" "system" fn NtWriteFile(filehandle : HANDLE, event : HANDLE, apcroutine : PIO_APC_ROUTINE, apccontext : *const core::ffi::c_void, iostatusblock : *mut IO_STATUS_BLOCK, buffer : *const core::ffi::c_void, length : u32, byteoffset : *const i64, key : *const u32) -> NTSTATUS);
78windows_link::link!("advapi32.dll" "system" fn OpenProcessToken(processhandle : HANDLE, desiredaccess : TOKEN_ACCESS_MASK, tokenhandle : *mut HANDLE) -> BOOL);
79windows_link::link!("kernel32.dll" "system" fn QueryPerformanceCounter(lpperformancecount : *mut i64) -> BOOL);
80windows_link::link!("kernel32.dll" "system" fn QueryPerformanceFrequency(lpfrequency : *mut i64) -> BOOL);
81windows_link::link!("kernel32.dll" "system" fn ReadConsoleW(hconsoleinput : HANDLE, lpbuffer : *mut core::ffi::c_void, nnumberofcharstoread : u32, lpnumberofcharsread : *mut u32, pinputcontrol : *const CONSOLE_READCONSOLE_CONTROL) -> BOOL);
82windows_link::link!("kernel32.dll" "system" fn ReadFile(hfile : HANDLE, lpbuffer : *mut u8, nnumberofbytestoread : u32, lpnumberofbytesread : *mut u32, lpoverlapped : *mut OVERLAPPED) -> BOOL);
83windows_link::link!("kernel32.dll" "system" fn ReadFileEx(hfile : HANDLE, lpbuffer : *mut u8, nnumberofbytestoread : u32, lpoverlapped : *mut OVERLAPPED, lpcompletionroutine : LPOVERLAPPED_COMPLETION_ROUTINE) -> BOOL);
84windows_link::link!("kernel32.dll" "system" fn ReleaseSRWLockExclusive(srwlock : *mut SRWLOCK));
85windows_link::link!("kernel32.dll" "system" fn ReleaseSRWLockShared(srwlock : *mut SRWLOCK));
86windows_link::link!("kernel32.dll" "system" fn RemoveDirectoryW(lppathname : PCWSTR) -> BOOL);
87windows_link::link!("advapi32.dll" "system" "SystemFunction036" fn RtlGenRandom(randombuffer : *mut core::ffi::c_void, randombufferlength : u32) -> bool);
88windows_link::link!("ntdll.dll" "system" fn RtlNtStatusToDosError(status : NTSTATUS) -> u32);
89windows_link::link!("kernel32.dll" "system" fn SetCurrentDirectoryW(lppathname : PCWSTR) -> BOOL);
90windows_link::link!("kernel32.dll" "system" fn SetEnvironmentVariableW(lpname : PCWSTR, lpvalue : PCWSTR) -> BOOL);
91windows_link::link!("kernel32.dll" "system" fn SetFileAttributesW(lpfilename : PCWSTR, dwfileattributes : FILE_FLAGS_AND_ATTRIBUTES) -> BOOL);
92windows_link::link!("kernel32.dll" "system" fn SetFileInformationByHandle(hfile : HANDLE, fileinformationclass : FILE_INFO_BY_HANDLE_CLASS, lpfileinformation : *const core::ffi::c_void, dwbuffersize : u32) -> BOOL);
93windows_link::link!("kernel32.dll" "system" fn SetFilePointerEx(hfile : HANDLE, lidistancetomove : i64, lpnewfilepointer : *mut i64, dwmovemethod : SET_FILE_POINTER_MOVE_METHOD) -> BOOL);
94windows_link::link!("kernel32.dll" "system" fn SetFileTime(hfile : HANDLE, lpcreationtime : *const FILETIME, lplastaccesstime : *const FILETIME, lplastwritetime : *const FILETIME) -> BOOL);
95windows_link::link!("kernel32.dll" "system" fn SetHandleInformation(hobject : HANDLE, dwmask : u32, dwflags : HANDLE_FLAGS) -> BOOL);
96windows_link::link!("kernel32.dll" "system" fn SetLastError(dwerrcode : WIN32_ERROR));
97windows_link::link!("kernel32.dll" "system" fn SetThreadStackGuarantee(stacksizeinbytes : *mut u32) -> BOOL);
98windows_link::link!("kernel32.dll" "system" fn SetWaitableTimer(htimer : HANDLE, lpduetime : *const i64, lperiod : i32, pfncompletionroutine : PTIMERAPCROUTINE, lpargtocompletionroutine : *const core::ffi::c_void, fresume : BOOL) -> BOOL);
99windows_link::link!("kernel32.dll" "system" fn Sleep(dwmilliseconds : u32));
100windows_link::link!("kernel32.dll" "system" fn SleepConditionVariableSRW(conditionvariable : *mut CONDITION_VARIABLE, srwlock : *mut SRWLOCK, dwmilliseconds : u32, flags : u32) -> BOOL);
101windows_link::link!("kernel32.dll" "system" fn SleepEx(dwmilliseconds : u32, balertable : BOOL) -> u32);
102windows_link::link!("kernel32.dll" "system" fn SwitchToThread() -> BOOL);
103windows_link::link!("kernel32.dll" "system" fn TerminateProcess(hprocess : HANDLE, uexitcode : u32) -> BOOL);
104windows_link::link!("kernel32.dll" "system" fn TlsAlloc() -> u32);
105windows_link::link!("kernel32.dll" "system" fn TlsFree(dwtlsindex : u32) -> BOOL);
106windows_link::link!("kernel32.dll" "system" fn TlsGetValue(dwtlsindex : u32) -> *mut core::ffi::c_void);
107windows_link::link!("kernel32.dll" "system" fn TlsSetValue(dwtlsindex : u32, lptlsvalue : *const core::ffi::c_void) -> BOOL);
108windows_link::link!("kernel32.dll" "system" fn TryAcquireSRWLockExclusive(srwlock : *mut SRWLOCK) -> bool);
109windows_link::link!("kernel32.dll" "system" fn TryAcquireSRWLockShared(srwlock : *mut SRWLOCK) -> bool);
110windows_link::link!("kernel32.dll" "system" fn UnlockFile(hfile : HANDLE, dwfileoffsetlow : u32, dwfileoffsethigh : u32, nnumberofbytestounlocklow : u32, nnumberofbytestounlockhigh : u32) -> BOOL);
111windows_link::link!("kernel32.dll" "system" fn UpdateProcThreadAttribute(lpattributelist : LPPROC_THREAD_ATTRIBUTE_LIST, dwflags : u32, attribute : usize, lpvalue : *const core::ffi::c_void, cbsize : usize, lppreviousvalue : *mut core::ffi::c_void, lpreturnsize : *const usize) -> BOOL);
112windows_link::link!("ws2_32.dll" "system" fn WSACleanup() -> i32);
113windows_link::link!("ws2_32.dll" "system" fn WSADuplicateSocketW(s : SOCKET, dwprocessid : u32, lpprotocolinfo : *mut WSAPROTOCOL_INFOW) -> i32);
114windows_link::link!("ws2_32.dll" "system" fn WSAGetLastError() -> WSA_ERROR);
115windows_link::link!("ws2_32.dll" "system" fn WSARecv(s : SOCKET, lpbuffers : *const WSABUF, dwbuffercount : u32, lpnumberofbytesrecvd : *mut u32, lpflags : *mut u32, lpoverlapped : *mut OVERLAPPED, lpcompletionroutine : LPWSAOVERLAPPED_COMPLETION_ROUTINE) -> i32);
116windows_link::link!("ws2_32.dll" "system" fn WSASend(s : SOCKET, lpbuffers : *const WSABUF, dwbuffercount : u32, lpnumberofbytessent : *mut u32, dwflags : u32, lpoverlapped : *mut OVERLAPPED, lpcompletionroutine : LPWSAOVERLAPPED_COMPLETION_ROUTINE) -> i32);
117windows_link::link!("ws2_32.dll" "system" fn WSASocketW(af : i32, r#type : i32, protocol : i32, lpprotocolinfo : *const WSAPROTOCOL_INFOW, g : u32, dwflags : u32) -> SOCKET);
118windows_link::link!("ws2_32.dll" "system" fn WSAStartup(wversionrequested : u16, lpwsadata : *mut WSADATA) -> i32);
119windows_link::link!("kernel32.dll" "system" fn WaitForMultipleObjects(ncount : u32, lphandles : *const HANDLE, bwaitall : BOOL, dwmilliseconds : u32) -> WAIT_EVENT);
120windows_link::link!("kernel32.dll" "system" fn WaitForSingleObject(hhandle : HANDLE, dwmilliseconds : u32) -> WAIT_EVENT);
121windows_link::link!("kernel32.dll" "system" fn WakeAllConditionVariable(conditionvariable : *mut CONDITION_VARIABLE));
122windows_link::link!("kernel32.dll" "system" fn WakeConditionVariable(conditionvariable : *mut CONDITION_VARIABLE));
123windows_link::link!("kernel32.dll" "system" fn WideCharToMultiByte(codepage : u32, dwflags : u32, lpwidecharstr : PCWSTR, cchwidechar : i32, lpmultibytestr : PSTR, cbmultibyte : i32, lpdefaultchar : PCSTR, lpuseddefaultchar : *mut BOOL) -> i32);
124windows_link::link!("kernel32.dll" "system" fn WriteConsoleW(hconsoleoutput : HANDLE, lpbuffer : PCWSTR, nnumberofcharstowrite : u32, lpnumberofcharswritten : *mut u32, lpreserved : *const core::ffi::c_void) -> BOOL);
125windows_link::link!("kernel32.dll" "system" fn WriteFileEx(hfile : HANDLE, lpbuffer : *const u8, nnumberofbytestowrite : u32, lpoverlapped : *mut OVERLAPPED, lpcompletionroutine : LPOVERLAPPED_COMPLETION_ROUTINE) -> BOOL);
126windows_link::link!("ws2_32.dll" "system" fn accept(s : SOCKET, addr : *mut SOCKADDR, addrlen : *mut i32) -> SOCKET);
127windows_link::link!("ws2_32.dll" "system" fn bind(s : SOCKET, name : *const SOCKADDR, namelen : i32) -> i32);
128windows_link::link!("ws2_32.dll" "system" fn closesocket(s : SOCKET) -> i32);
129windows_link::link!("ws2_32.dll" "system" fn connect(s : SOCKET, name : *const SOCKADDR, namelen : i32) -> i32);
130windows_link::link!("ws2_32.dll" "system" fn freeaddrinfo(paddrinfo : *const ADDRINFOA));
131windows_link::link!("ws2_32.dll" "system" fn getaddrinfo(pnodename : PCSTR, pservicename : PCSTR, phints : *const ADDRINFOA, ppresult : *mut *mut ADDRINFOA) -> i32);
132windows_link::link!("ws2_32.dll" "system" fn getpeername(s : SOCKET, name : *mut SOCKADDR, namelen : *mut i32) -> i32);
133windows_link::link!("ws2_32.dll" "system" fn getsockname(s : SOCKET, name : *mut SOCKADDR, namelen : *mut i32) -> i32);
134windows_link::link!("ws2_32.dll" "system" fn getsockopt(s : SOCKET, level : i32, optname : i32, optval : PSTR, optlen : *mut i32) -> i32);
135windows_link::link!("ws2_32.dll" "system" fn ioctlsocket(s : SOCKET, cmd : i32, argp : *mut u32) -> i32);
136windows_link::link!("ws2_32.dll" "system" fn listen(s : SOCKET, backlog : i32) -> i32);
137windows_link::link!("kernel32.dll" "system" fn lstrlenW(lpstring : PCWSTR) -> i32);
138windows_link::link!("ws2_32.dll" "system" fn recv(s : SOCKET, buf : PSTR, len : i32, flags : SEND_RECV_FLAGS) -> i32);
139windows_link::link!("ws2_32.dll" "system" fn recvfrom(s : SOCKET, buf : PSTR, len : i32, flags : i32, from : *mut SOCKADDR, fromlen : *mut i32) -> i32);
140windows_link::link!("ws2_32.dll" "system" fn select(nfds : i32, readfds : *mut FD_SET, writefds : *mut FD_SET, exceptfds : *mut FD_SET, timeout : *const TIMEVAL) -> i32);
141windows_link::link!("ws2_32.dll" "system" fn send(s : SOCKET, buf : PCSTR, len : i32, flags : SEND_RECV_FLAGS) -> i32);
142windows_link::link!("ws2_32.dll" "system" fn sendto(s : SOCKET, buf : PCSTR, len : i32, flags : i32, to : *const SOCKADDR, tolen : i32) -> i32);
143windows_link::link!("ws2_32.dll" "system" fn setsockopt(s : SOCKET, level : i32, optname : i32, optval : PCSTR, optlen : i32) -> i32);
144windows_link::link!("ws2_32.dll" "system" fn shutdown(s : SOCKET, how : WINSOCK_SHUTDOWN_HOW) -> i32);
145145pub const ABOVE_NORMAL_PRIORITY_CLASS: PROCESS_CREATION_FLAGS = 32768u32;
146146#[repr(C)]
147147#[derive(Clone, Copy, Default)]
library/std/tests/env_modify.rs-1
......@@ -99,7 +99,6 @@ fn test_env_set_var() {
9999
100100#[test]
101101#[cfg_attr(not(any(unix, windows)), ignore, allow(unused))]
102#[allow(deprecated)]
103102fn env_home_dir() {
104103 use std::path::PathBuf;
105104
library/test/src/term/terminfo/searcher.rs-1
......@@ -9,7 +9,6 @@ use std::{env, fs};
99mod tests;
1010
1111/// Returns path to database entry for `term`
12#[allow(deprecated)]
1312pub(crate) fn get_dbpath_for_term(term: &str) -> Option<PathBuf> {
1413 let mut dirs_to_search = Vec::new();
1514 let first_char = term.chars().next()?;
library/windows_link/Cargo.toml created+15
......@@ -0,0 +1,15 @@
1[package]
2name = "windows-link"
3description = "A drop-in replacement for the real windows-link crate for use in std only."
4version = "0.0.0"
5edition = "2024"
6
7[lib]
8test = false
9bench = false
10doc = false
11
12[features]
13# Enable using raw-dylib for Windows imports.
14# This will eventually be the default.
15windows_raw_dylib = []
library/windows_link/src/lib.rs created+52
......@@ -0,0 +1,52 @@
1//! Provides the `link!` macro used by the generated windows bindings.
2//!
3//! This is a simple wrapper around an `extern` block with a `#[link]` attribute.
4//! It's very roughly equivalent to the windows-targets crate.
5#![no_std]
6#![no_core]
7#![feature(decl_macro)]
8#![feature(no_core)]
9
10pub macro link_raw_dylib {
11 ($library:literal $abi:literal $($link_name:literal)? $(#[$doc:meta])? fn $($function:tt)*) => (
12 #[cfg_attr(not(target_arch = "x86"), link(name = $library, kind = "raw-dylib", modifiers = "+verbatim"))]
13 #[cfg_attr(target_arch = "x86", link(name = $library, kind = "raw-dylib", modifiers = "+verbatim", import_name_type = "undecorated"))]
14 unsafe extern $abi {
15 $(#[link_name=$link_name])?
16 pub fn $($function)*;
17 }
18 )
19}
20
21pub macro link_dylib {
22 ($library:literal $abi:literal $($link_name:literal)? $(#[$doc:meta])? fn $($function:tt)*) => (
23 // Note: the windows-targets crate uses a pre-built Windows.lib import library which we don't
24 // have in this repo. So instead we always link kernel32.lib and add the rest of the import
25 // libraries below by using an empty extern block. This works because extern blocks are not
26 // connected to the library given in the #[link] attribute.
27 #[link(name = "kernel32")]
28 unsafe extern $abi {
29 $(#[link_name=$link_name])?
30 pub fn $($function)*;
31 }
32 )
33}
34
35#[cfg(feature = "windows_raw_dylib")]
36pub macro link($($tt:tt)*) {
37 $crate::link_raw_dylib!($($tt)*);
38}
39
40#[cfg(not(feature = "windows_raw_dylib"))]
41pub macro link($($tt:tt)*) {
42 $crate::link_dylib!($($tt)*);
43}
44
45#[cfg(not(feature = "windows_raw_dylib"))]
46#[cfg(not(target_os = "cygwin"))] // Cygwin doesn't need these libs
47#[cfg_attr(target_vendor = "win7", link(name = "advapi32"))]
48#[link(name = "ntdll")]
49#[link(name = "userenv")]
50#[link(name = "ws2_32")]
51#[link(name = "dbghelp")] // required for backtrace-rs symbolization
52unsafe extern "C" {}
library/windows_targets/Cargo.toml deleted-15
......@@ -1,15 +0,0 @@
1[package]
2name = "windows-targets"
3description = "A drop-in replacement for the real windows-targets crate for use in std only."
4version = "0.0.0"
5edition = "2024"
6
7[lib]
8test = false
9bench = false
10doc = false
11
12[features]
13# Enable using raw-dylib for Windows imports.
14# This will eventually be the default.
15windows_raw_dylib = []
library/windows_targets/src/lib.rs deleted-52
......@@ -1,52 +0,0 @@
1//! Provides the `link!` macro used by the generated windows bindings.
2//!
3//! This is a simple wrapper around an `extern` block with a `#[link]` attribute.
4//! It's very roughly equivalent to the windows-targets crate.
5#![no_std]
6#![no_core]
7#![feature(decl_macro)]
8#![feature(no_core)]
9
10pub macro link_raw_dylib {
11 ($library:literal $abi:literal $($link_name:literal)? $(#[$doc:meta])? fn $($function:tt)*) => (
12 #[cfg_attr(not(target_arch = "x86"), link(name = $library, kind = "raw-dylib", modifiers = "+verbatim"))]
13 #[cfg_attr(target_arch = "x86", link(name = $library, kind = "raw-dylib", modifiers = "+verbatim", import_name_type = "undecorated"))]
14 unsafe extern $abi {
15 $(#[link_name=$link_name])?
16 pub fn $($function)*;
17 }
18 )
19}
20
21pub macro link_dylib {
22 ($library:literal $abi:literal $($link_name:literal)? $(#[$doc:meta])? fn $($function:tt)*) => (
23 // Note: the windows-targets crate uses a pre-built Windows.lib import library which we don't
24 // have in this repo. So instead we always link kernel32.lib and add the rest of the import
25 // libraries below by using an empty extern block. This works because extern blocks are not
26 // connected to the library given in the #[link] attribute.
27 #[link(name = "kernel32")]
28 unsafe extern $abi {
29 $(#[link_name=$link_name])?
30 pub fn $($function)*;
31 }
32 )
33}
34
35#[cfg(feature = "windows_raw_dylib")]
36pub macro link($($tt:tt)*) {
37 $crate::link_raw_dylib!($($tt)*);
38}
39
40#[cfg(not(feature = "windows_raw_dylib"))]
41pub macro link($($tt:tt)*) {
42 $crate::link_dylib!($($tt)*);
43}
44
45#[cfg(not(feature = "windows_raw_dylib"))]
46#[cfg(not(target_os = "cygwin"))] // Cygwin doesn't need these libs
47#[cfg_attr(target_vendor = "win7", link(name = "advapi32"))]
48#[link(name = "ntdll")]
49#[link(name = "userenv")]
50#[link(name = "ws2_32")]
51#[link(name = "dbghelp")] // required for backtrace-rs symbolization
52unsafe extern "C" {}
src/bootstrap/src/core/sanity.rs+2
......@@ -46,6 +46,8 @@ const STAGE0_MISSING_TARGETS: &[&str] = &[
4646 "armv6-none-eabi",
4747 "armv6-none-eabihf",
4848 "thumbv6-none-eabi",
49 "aarch64v8r-unknown-none",
50 "aarch64v8r-unknown-none-softfloat",
4951];
5052
5153/// Minimum version threshold for libstdc++ required when using prebuilt LLVM
src/doc/reference+1-1
......@@ -1 +1 @@
1Subproject commit 28b5a54419985f03db5294de5eede71b6665b594
1Subproject commit 990819b86c22bbf538c0526f0287670f3dc1a67a
src/doc/rust-by-example+1-1
......@@ -1 +1 @@
1Subproject commit 8de6ff811315ac3a96ebe01d74057382e42ffdee
1Subproject commit bac931ef1673af63fb60c3d691633034713cca20
src/doc/rustc/src/SUMMARY.md+1
......@@ -50,6 +50,7 @@
5050 - [aarch64-unknown-linux-gnu](platform-support/aarch64-unknown-linux-gnu.md)
5151 - [aarch64-unknown-linux-musl](platform-support/aarch64-unknown-linux-musl.md)
5252 - [aarch64-unknown-none*](platform-support/aarch64-unknown-none.md)
53 - [aarch64v8r-unknown-none*](platform-support/aarch64v8r-unknown-none.md)
5354 - [aarch64_be-unknown-none-softfloat](platform-support/aarch64_be-unknown-none-softfloat.md)
5455 - [aarch64_be-unknown-linux-musl](platform-support/aarch64_be-unknown-linux-musl.md)
5556 - [amdgcn-amd-amdhsa](platform-support/amdgcn-amd-amdhsa.md)
src/doc/rustc/src/platform-support.md+2
......@@ -275,6 +275,8 @@ target | std | host | notes
275275[`aarch64-unknown-trusty`](platform-support/trusty.md) | ✓ | |
276276[`aarch64-uwp-windows-msvc`](platform-support/uwp-windows-msvc.md) | ✓ | |
277277[`aarch64-wrs-vxworks`](platform-support/vxworks.md) | ✓ | | ARM64 VxWorks OS
278[`aarch64v8r-unknown-none`](platform-support/aarch64v8r-unknown-none.md) | * | | Bare Armv8-R in AArch64 mode, hardfloat
279[`aarch64v8r-unknown-none-softfloat`](platform-support/aarch64v8r-unknown-none.md) | * | | Bare Armv8-R in AArch64 mode, softfloat
278280[`aarch64_be-unknown-hermit`](platform-support/hermit.md) | ✓ | | ARM64 Hermit (big-endian)
279281`aarch64_be-unknown-linux-gnu` | ✓ | ✓ | ARM64 Linux (big-endian)
280282`aarch64_be-unknown-linux-gnu_ilp32` | ✓ | ✓ | ARM64 Linux (big-endian, ILP32 ABI)
src/doc/rustc/src/platform-support/aarch64v8r-unknown-none.md created+84
......@@ -0,0 +1,84 @@
1# `aarch64v8r-unknown-none` and `aarch64v8r-unknown-none-softfloat`
2
3* **Tier: 3**
4* **Library Support:** core and alloc (bare-metal, `#![no_std]`)
5
6Bare-metal target for CPUs in the Armv8-R architecture family, running in
7AArch64 mode. Processors in this family include the
8[Arm Cortex-R82][cortex-r82].
9
10For Armv8-R CPUs running in AArch32 mode (such as the Arm Cortex-R52), see
11[`armv8r-none-eabihf`](armv8r-none-eabihf.md) instead.
12
13[cortex-r82]: https://developer.arm.com/processors/Cortex-R82
14
15## Target maintainers
16
17- [Rust Embedded Devices Working Group Arm Team]
18- [@rust-lang/arm-maintainers][arm_maintainers] ([rust@arm.com][arm_email])
19
20[Rust Embedded Devices Working Group Arm Team]: https://github.com/rust-embedded/wg?tab=readme-ov-file#the-arm-team
21[arm_maintainers]: https://github.com/rust-lang/team/blob/master/teams/arm-maintainers.toml
22[arm_email]: mailto:rust@arm.com
23
24## Target CPU and Target Feature options
25
26Unlike AArch64 v8-A processors, not all AArch64 v8-R processors include an FPU
27(that is, not all Armv8-R AArch64 processors implement the optional Armv8
28`FEAT_FP` extension). If you do not have an FPU, or have an FPU but wish to use
29a soft-float ABI anyway, you should use the `aarch64v8r-unknown-none-softfloat`
30target. If you wish to use the standard hard-float Arm AArch64 calling
31convention, and you have an FPU, you can use the `aarch64v8r-unknown-none`
32target.
33
34When using the `aarch64v8r-unknown-none` target, the minimum floating-point
35features assumed are the Advanced SIMD features (`FEAT_AdvSIMD`, or `+neon`),
36the implementation of which is branded Arm NEON.
37
38If your processor supports a different set of floating-point features than the
39default expectations then these should also be enabled or disabled as needed
40with [`-C target-feature=(+/-)`][target-feature]. However, note that currently
41Rust does not support building hard-float AArch64 targets with Advanced SIMD
42support disabled. It is also possible to tell Rust (or LLVM) that you have a
43specific model of Arm processor, using the [`-Ctarget-cpu`][target-cpu] option.
44Doing so may change the default set of target-features enabled.
45
46[target-feature]: https://doc.rust-lang.org/rustc/codegen-options/index.html#target-feature
47[target-cpu]: https://doc.rust-lang.org/rustc/codegen-options/index.html#target-cpu
48
49## Requirements
50
51These targets are cross-compiled and use static linking.
52
53By default, the `lld` linker included with Rust will be used; however, you may
54want to use the GNU linker instead. This can be obtained for Windows/Mac/Linux
55from the [Arm Developer Website][arm-gnu-toolchain], or possibly from your OS's
56package manager. To use it, add the following to your `.cargo/config.toml`:
57
58```toml
59[target.aarch64-unknown-none]
60linker = "aarch64-none-elf-ld"
61```
62
63The GNU linker can also be used by specifying `aarch64-none-elf-gcc` as the
64linker. This is needed when using GCC's link time optimization.
65
66These targets don't provide a linker script, so you'll need to bring your own
67according to the specific device you are using. Pass
68`-Clink-arg=-Tyour_script.ld` as a rustc argument to make the linker use
69`your_script.ld` during linking.
70
71[arm-gnu-toolchain]: https://developer.arm.com/Tools%20and%20Software/GNU%20Toolchain
72
73## Cross-compilation toolchains and C code
74
75This target supports C code compiled with the `aarch64-none-elf` target
76triple and a suitable `-march` or `-mcpu` flag.
77
78## Start-up and Low-Level Code
79
80The [Rust Embedded Devices Working Group Arm Team] maintain the
81[`aarch64-cpu`] crate, which may be useful for writing bare-metal code using
82this target.
83
84[`aarch64-cpu`]: https://docs.rs/aarch64-cpu
src/doc/rustc/src/platform-support/armv8r-none-eabihf.md+3
......@@ -15,6 +15,9 @@ and [Cortex-R52+][cortex-r52-plus].
1515See [`arm-none-eabi`](arm-none-eabi.md) for information applicable to all
1616`arm-none-eabi` targets.
1717
18For Armv8-R CPUs running in AArch64 mode (such as the Arm Cortex-R82), see
19[`aarch64v8r-unknown-none`](aarch64v8r-unknown-none.md) instead.
20
1821[cortex-r52]: https://www.arm.com/products/silicon-ip-cpu/cortex-r/cortex-r52
1922[cortex-r52-plus]: https://www.arm.com/products/silicon-ip-cpu/cortex-r/cortex-r52-plus
2023
src/doc/rustc/src/platform-support/xtensa.md+1-1
......@@ -24,4 +24,4 @@ Xtensa targets that support `std` are documented in the [ESP-IDF platform suppor
2424
2525## Building the targets
2626
27The targets can be built by installing the [Xtensa enabled Rust channel](https://github.com/esp-rs/rust/). See instructions in the [RISC-V and Xtensa Targets section of The Rust on ESP Book](https://docs.espressif.com/projects/rust/book/installation/index.html).
27The targets can be built by installing the [Xtensa enabled Rust channel](https://github.com/esp-rs/rust/). See instructions in the [RISC-V and Xtensa Targets section of The Rust on ESP Book](https://docs.espressif.com/projects/rust/book/getting-started/toolchain.html).
src/doc/unstable-book/src/language-features/asm-experimental-arch.md+2-39
......@@ -8,7 +8,6 @@ The tracking issue for this feature is: [#93335]
88
99This feature tracks `asm!` and `global_asm!` support for the following architectures:
1010- NVPTX
11- PowerPC
1211- Hexagon
1312- MIPS32r2 and MIPS64r2
1413- wasm32
......@@ -31,16 +30,6 @@ This feature tracks `asm!` and `global_asm!` support for the following architect
3130| NVPTX | `reg64` | None\* | `l` |
3231| Hexagon | `reg` | `r[0-28]` | `r` |
3332| Hexagon | `preg` | `p[0-3]` | Only clobbers |
34| PowerPC | `reg` | `r0`, `r[3-12]`, `r[14-29]`\* | `r` |
35| PowerPC | `reg_nonzero` | `r[3-12]`, `r[14-29]`\* | `b` |
36| PowerPC | `freg` | `f[0-31]` | `f` |
37| PowerPC | `vreg` | `v[0-31]` | `v` |
38| PowerPC | `vsreg | `vs[0-63]` | `wa` |
39| PowerPC | `cr` | `cr[0-7]`, `cr` | Only clobbers |
40| PowerPC | `ctr` | `ctr` | Only clobbers |
41| PowerPC | `lr` | `lr` | Only clobbers |
42| PowerPC | `xer` | `xer` | Only clobbers |
43| PowerPC | `spe_acc` | `spe_acc` | Only clobbers |
4433| wasm32 | `local` | None\* | `r` |
4534| BPF | `reg` | `r[0-10]` | `r` |
4635| BPF | `wreg` | `w[0-10]` | `w` |
......@@ -62,10 +51,6 @@ This feature tracks `asm!` and `global_asm!` support for the following architect
6251> - NVPTX doesn't have a fixed register set, so named registers are not supported.
6352>
6453> - WebAssembly doesn't have registers, so named registers are not supported.
65>
66> - r29 is reserved only on 32 bit PowerPC targets.
67>
68> - spe_acc is only available on PowerPC SPE targets.
6954
7055# Register class supported types
7156
......@@ -80,17 +65,6 @@ This feature tracks `asm!` and `global_asm!` support for the following architect
8065| NVPTX | `reg64` | None | `i8`, `i16`, `i32`, `f32`, `i64`, `f64` |
8166| Hexagon | `reg` | None | `i8`, `i16`, `i32`, `f32` |
8267| Hexagon | `preg` | N/A | Only clobbers |
83| PowerPC | `reg` | None | `i8`, `i16`, `i32`, `i64` (powerpc64 only) |
84| PowerPC | `reg_nonzero` | None | `i8`, `i16`, `i32`, `i64` (powerpc64 only) |
85| PowerPC | `freg` | None | `f32`, `f64` |
86| PowerPC | `vreg` | `altivec` | `i8x16`, `i16x8`, `i32x4`, `f32x4` |
87| PowerPC | `vreg` | `vsx` | `f32`, `f64`, `i64x2`, `f64x2` |
88| PowerPC | `vsreg` | `vsx` | The union of vsx and altivec vreg types |
89| PowerPC | `cr` | N/A | Only clobbers |
90| PowerPC | `ctr` | N/A | Only clobbers |
91| PowerPC | `lr` | N/A | Only clobbers |
92| PowerPC | `xer` | N/A | Only clobbers |
93| PowerPC | `spe_acc` | N/A | Only clobbers |
9468| wasm32 | `local` | None | `i8` `i16` `i32` `i64` `f32` `f64` |
9569| BPF | `reg` | None | `i8` `i16` `i32` `i64` |
9670| BPF | `wreg` | `alu32` | `i8` `i16` `i32` |
......@@ -111,10 +85,6 @@ This feature tracks `asm!` and `global_asm!` support for the following architect
11185| Hexagon | `r29` | `sp` |
11286| Hexagon | `r30` | `fr` |
11387| Hexagon | `r31` | `lr` |
114| PowerPC | `r1` | `sp` |
115| PowerPC | `r31` | `fp` |
116| PowerPC | `r[0-31]` | `[0-31]` |
117| PowerPC | `f[0-31]` | `fr[0-31]`|
11888| BPF | `r[0-10]` | `w[0-10]` |
11989| AVR | `XH` | `r27` |
12090| AVR | `XL` | `r26` |
......@@ -153,16 +123,14 @@ This feature tracks `asm!` and `global_asm!` support for the following architect
153123| Architecture | Unsupported register | Reason |
154124| ------------ | --------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
155125| All | `sp`, `r14`/`o6` (SPARC) | The stack pointer must be restored to its original value at the end of an asm code block. |
156| All | `fr` (Hexagon), `fp` (PowerPC), `$fp` (MIPS), `Y` (AVR), `r4` (MSP430), `a6` (M68k), `r30`/`i6` (SPARC) | The frame pointer cannot be used as an input or output. |
157| All | `r19` (Hexagon), `r29` (PowerPC 32 bit only), `r30` (PowerPC) | These are used internally by LLVM as "base pointer" for functions with complex stack frames. |
126| All | `fr` (Hexagon) `$fp` (MIPS), `Y` (AVR), `r4` (MSP430), `a6` (M68k), `r30`/`i6` (SPARC) | The frame pointer cannot be used as an input or output. |
127| All | `r19` (Hexagon) | These are used internally by LLVM as "base pointer" for functions with complex stack frames. |
158128| MIPS | `$0` or `$zero` | This is a constant zero register which can't be modified. |
159129| MIPS | `$1` or `$at` | Reserved for assembler. |
160130| MIPS | `$26`/`$k0`, `$27`/`$k1` | OS-reserved registers. |
161131| MIPS | `$28`/`$gp` | Global pointer cannot be used as inputs or outputs. |
162132| MIPS | `$ra` | Return address cannot be used as inputs or outputs. |
163133| Hexagon | `lr` | This is the link register which cannot be used as an input or output. |
164| PowerPC | `r2`, `r13` | These are system reserved registers. |
165| PowerPC | `vrsave` | The vrsave register cannot be used as an input or output. |
166134| AVR | `r0`, `r1`, `r1r0` | Due to an issue in LLVM, the `r0` and `r1` registers cannot be used as inputs or outputs. If modified, they must be restored to their original values before the end of the block. |
167135|MSP430 | `r0`, `r2`, `r3` | These are the program counter, status register, and constant generator respectively. Neither the status register nor constant generator can be written to. |
168136| M68k | `a4`, `a5` | Used internally by LLVM for the base pointer and global base pointer. |
......@@ -189,11 +157,6 @@ This feature tracks `asm!` and `global_asm!` support for the following architect
189157| NVPTX | `reg32` | None | `r0` | None |
190158| NVPTX | `reg64` | None | `rd0` | None |
191159| Hexagon | `reg` | None | `r0` | None |
192| PowerPC | `reg` | None | `0` | None |
193| PowerPC | `reg_nonzero` | None | `3` | None |
194| PowerPC | `freg` | None | `0` | None |
195| PowerPC | `vreg` | None | `0` | None |
196| PowerPC | `vsreg` | None | `0` | None |
197160| SPARC | `reg` | None | `%o0` | None |
198161| CSKY | `reg` | None | `r0` | None |
199162| CSKY | `freg` | None | `f0` | None |
src/tools/clippy/tests/ui/recursive_format_impl.stderr-18
......@@ -12,72 +12,54 @@ error: using `self` as `Display` in `impl Display` will cause infinite recursion
1212 |
1313LL | write!(f, "{}", self)
1414 | ^^^^^^^^^^^^^^^^^^^^^
15 |
16 = note: this error originates in the macro `write` (in Nightly builds, run with -Z macro-backtrace for more info)
1715
1816error: using `self` as `Display` in `impl Display` will cause infinite recursion
1917 --> tests/ui/recursive_format_impl.rs:86:9
2018 |
2119LL | write!(f, "{}", &self)
2220 | ^^^^^^^^^^^^^^^^^^^^^^
23 |
24 = note: this error originates in the macro `write` (in Nightly builds, run with -Z macro-backtrace for more info)
2521
2622error: using `self` as `Debug` in `impl Debug` will cause infinite recursion
2723 --> tests/ui/recursive_format_impl.rs:93:9
2824 |
2925LL | write!(f, "{:?}", &self)
3026 | ^^^^^^^^^^^^^^^^^^^^^^^^
31 |
32 = note: this error originates in the macro `write` (in Nightly builds, run with -Z macro-backtrace for more info)
3327
3428error: using `self` as `Display` in `impl Display` will cause infinite recursion
3529 --> tests/ui/recursive_format_impl.rs:103:9
3630 |
3731LL | write!(f, "{}", &&&self)
3832 | ^^^^^^^^^^^^^^^^^^^^^^^^
39 |
40 = note: this error originates in the macro `write` (in Nightly builds, run with -Z macro-backtrace for more info)
4133
4234error: using `self` as `Display` in `impl Display` will cause infinite recursion
4335 --> tests/ui/recursive_format_impl.rs:178:9
4436 |
4537LL | write!(f, "{}", &*self)
4638 | ^^^^^^^^^^^^^^^^^^^^^^^
47 |
48 = note: this error originates in the macro `write` (in Nightly builds, run with -Z macro-backtrace for more info)
4939
5040error: using `self` as `Debug` in `impl Debug` will cause infinite recursion
5141 --> tests/ui/recursive_format_impl.rs:185:9
5242 |
5343LL | write!(f, "{:?}", &*self)
5444 | ^^^^^^^^^^^^^^^^^^^^^^^^^
55 |
56 = note: this error originates in the macro `write` (in Nightly builds, run with -Z macro-backtrace for more info)
5745
5846error: using `self` as `Display` in `impl Display` will cause infinite recursion
5947 --> tests/ui/recursive_format_impl.rs:202:9
6048 |
6149LL | write!(f, "{}", *self)
6250 | ^^^^^^^^^^^^^^^^^^^^^^
63 |
64 = note: this error originates in the macro `write` (in Nightly builds, run with -Z macro-backtrace for more info)
6551
6652error: using `self` as `Display` in `impl Display` will cause infinite recursion
6753 --> tests/ui/recursive_format_impl.rs:219:9
6854 |
6955LL | write!(f, "{}", **&&*self)
7056 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
71 |
72 = note: this error originates in the macro `write` (in Nightly builds, run with -Z macro-backtrace for more info)
7357
7458error: using `self` as `Display` in `impl Display` will cause infinite recursion
7559 --> tests/ui/recursive_format_impl.rs:236:9
7660 |
7761LL | write!(f, "{}", &&**&&*self)
7862 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
79 |
80 = note: this error originates in the macro `write` (in Nightly builds, run with -Z macro-backtrace for more info)
8163
8264error: aborting due to 10 previous errors
8365
src/tools/generate-windows-sys/Cargo.toml+1-1
......@@ -4,4 +4,4 @@ version = "0.1.0"
44edition = "2021"
55
66[dependencies.windows-bindgen]
7version = "0.61.0"
7version = "0.66.0"
src/tools/generate-windows-sys/src/main.rs+1-1
......@@ -29,7 +29,7 @@ fn main() -> Result<(), Box<dyn Error>> {
2929
3030 sort_bindings("bindings.txt")?;
3131
32 windows_bindgen::bindgen(["--etc", "bindings.txt"]);
32 windows_bindgen::bindgen(["--etc", "bindings.txt"]).unwrap();
3333
3434 let mut f = std::fs::File::options().append(true).open("windows_sys.rs")?;
3535 f.write_all(ARM32_SHIM.as_bytes())?;
src/tools/miri/tests/fail-dep/concurrency/windows_join_main.stderr-1
......@@ -31,7 +31,6 @@ LL | | assert_eq!(WaitForSingleObject(MAIN_THREAD, INFINITE), WAIT_O
3131LL | | }
3232LL | | })
3333 | |______^
34 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
3534
3635note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
3736
src/tools/miri/tests/fail/dangling_pointers/dangling_primitive.stderr-1
......@@ -16,7 +16,6 @@ help: ALLOC was deallocated here:
1616 |
1717LL | };
1818 | ^
19 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
2019
2120note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
2221
src/tools/miri/tests/fail/dangling_pointers/out_of_bounds_read.stderr-1
......@@ -11,7 +11,6 @@ help: ALLOC was allocated here:
1111 |
1212LL | let v: Vec<u16> = vec![1, 2];
1313 | ^^^^^^^^^^
14 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
1716
src/tools/miri/tests/fail/dangling_pointers/out_of_bounds_read_neg_offset.stderr-1
......@@ -11,7 +11,6 @@ help: ALLOC was allocated here:
1111 |
1212LL | let v: Vec<u16> = vec![1, 2];
1313 | ^^^^^^^^^^
14 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
1716
src/tools/miri/tests/fail/dangling_pointers/out_of_bounds_write.stderr-1
......@@ -11,7 +11,6 @@ help: ALLOC was allocated here:
1111 |
1212LL | let mut v: Vec<u16> = vec![1, 2];
1313 | ^^^^^^^^^^
14 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
1716
src/tools/miri/tests/fail/erroneous_const2.stderr-2
......@@ -23,8 +23,6 @@ note: erroneous constant encountered
2323 |
2424LL | println!("{}", FOO);
2525 | ^^^
26 |
27 = note: this note originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2826
2927error: aborting due to 1 previous error
3028
src/tools/miri/tests/fail/function_calls/return_pointer_on_unwind.stderr-1
......@@ -11,7 +11,6 @@ LL | dbg!(x.0);
1111 |
1212 = help: this indicates a bug in the program: it performed an invalid operation, and caused Undefined Behavior
1313 = help: see https://doc.rust-lang.org/nightly/reference/behavior-considered-undefined.html for further information
14 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615Uninitialized memory occurred at ALLOC[0x0..0x4], in this allocation:
1716ALLOC (stack variable, size: 132, align: 4) {
src/tools/miri/tests/fail/intrinsics/simd-scatter.stderr-1
......@@ -16,7 +16,6 @@ help: ALLOC was allocated here:
1616 |
1717LL | let mut vec: Vec<i8> = vec![10, 11, 12, 13, 14, 15, 16, 17, 18];
1818 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
19 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
2019
2120note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
2221
src/tools/miri/tests/fail/provenance/mix-ptrs1.stderr-1
......@@ -6,7 +6,6 @@ LL | assert_eq!(*strange_ptr.with_addr(ptr.addr()), 0);
66 |
77 = help: this indicates a bug in the program: it performed an invalid operation, and caused Undefined Behavior
88 = help: see https://doc.rust-lang.org/nightly/reference/behavior-considered-undefined.html for further information
9 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
109
1110note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
1211
src/tools/miri/tests/fail/provenance/mix-ptrs2.stderr-1
......@@ -6,7 +6,6 @@ LL | assert_eq!(*ptr, 42);
66 |
77 = help: this indicates a bug in the program: it performed an invalid operation, and caused Undefined Behavior
88 = help: see https://doc.rust-lang.org/nightly/reference/behavior-considered-undefined.html for further information
9 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
109
1110note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
1211
src/tools/miri/tests/fail/rc_as_ptr.stderr-1
......@@ -16,7 +16,6 @@ help: ALLOC was deallocated here:
1616 |
1717LL | drop(strong);
1818 | ^^^^^^^^^^^^
19 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
2019
2120note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
2221
src/tools/miri/tests/fail/stacked_borrows/zst_slice.stderr-1
......@@ -11,7 +11,6 @@ help: <TAG> would have been created here, but this is a zero-size retag ([0x0..0
1111 |
1212LL | assert_eq!(*s.as_ptr().add(1), 2);
1313 | ^^^^^^^^^^
14 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
1716
src/tools/miri/tests/fail/tree_borrows/parent_read_freezes_raw_mut.stderr-1
......@@ -24,7 +24,6 @@ help: the accessed tag <TAG> later transitioned to Frozen due to a reborrow (act
2424LL | assert_eq!(root, 0); // Parent Read
2525 | ^^^^^^^^^^^^^^^^^^^
2626 = help: this transition corresponds to a loss of write permissions
27 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
2827
2928note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
3029
src/tools/miri/tests/fail/tree_borrows/protector-write-lazy.stderr-1
......@@ -18,7 +18,6 @@ help: the accessed tag <TAG> later transitioned to Disabled due to a protector r
1818LL | }
1919 | ^
2020 = help: this transition corresponds to a loss of read and write permissions
21 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2221
2322note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
2423
src/tools/miri/tests/pass/alloc-access-tracking.stderr-2
......@@ -15,8 +15,6 @@ note: read access at ALLOC[0..1]
1515 |
1616LL | assert_eq!(*ptr, 42);
1717 | ^^^^^^^^^^^^^^^^^^^^ tracking was triggered here
18 |
19 = note: this note originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
2018
2119note: freed allocation ALLOC
2220 --> RUSTLIB/alloc/src/boxed.rs:LL:CC
src/tools/tidy/src/pal.rs+1-1
......@@ -38,7 +38,7 @@ use crate::walk::{filter_dirs, walk};
3838const EXCEPTION_PATHS: &[&str] = &[
3939 "library/compiler-builtins",
4040 "library/std_detect",
41 "library/windows_targets",
41 "library/windows_link",
4242 "library/panic_abort",
4343 "library/panic_unwind",
4444 "library/unwind",
src/tools/tidy/src/target_specific_tests.rs+1-1
......@@ -98,7 +98,7 @@ fn arch_to_llvm_component(arch: &str) -> String {
9898 // enough for the purpose of this tidy check.
9999 match arch {
100100 "amdgcn" => "amdgpu".into(),
101 "aarch64_be" | "arm64_32" | "arm64e" | "arm64ec" => "aarch64".into(),
101 "aarch64v8r" | "aarch64_be" | "arm64_32" | "arm64e" | "arm64ec" => "aarch64".into(),
102102 "i386" | "i586" | "i686" | "x86" | "x86_64" | "x86_64h" => "x86".into(),
103103 "loongarch32" | "loongarch64" => "loongarch".into(),
104104 "nvptx64" => "nvptx".into(),
tests/assembly-llvm/targets/targets-elf.rs+6
......@@ -67,6 +67,12 @@
6767//@ revisions: aarch64_unknown_none_softfloat
6868//@ [aarch64_unknown_none_softfloat] compile-flags: --target aarch64-unknown-none-softfloat
6969//@ [aarch64_unknown_none_softfloat] needs-llvm-components: aarch64
70//@ revisions: aarch64v8r_unknown_none
71//@ [aarch64v8r_unknown_none] compile-flags: --target aarch64v8r-unknown-none
72//@ [aarch64v8r_unknown_none] needs-llvm-components: aarch64
73//@ revisions: aarch64v8r_unknown_none_softfloat
74//@ [aarch64v8r_unknown_none_softfloat] compile-flags: --target aarch64v8r-unknown-none-softfloat
75//@ [aarch64v8r_unknown_none_softfloat] needs-llvm-components: aarch64
7076//@ revisions: aarch64_unknown_nto_qnx700
7177//@ [aarch64_unknown_nto_qnx700] compile-flags: --target aarch64-unknown-nto-qnx700
7278//@ [aarch64_unknown_nto_qnx700] needs-llvm-components: aarch64
tests/codegen-llvm/aarch64v8r-softfloat.rs created+45
......@@ -0,0 +1,45 @@
1//@ add-minicore
2//@ compile-flags: --target aarch64v8r-unknown-none-softfloat -Zmerge-functions=disabled
3//@ needs-llvm-components: aarch64
4#![crate_type = "lib"]
5#![feature(no_core, lang_items)]
6#![no_core]
7
8extern crate minicore;
9use minicore::*;
10
11// CHECK: i64 @pass_f64_C(i64 {{[^,]*}})
12#[no_mangle]
13extern "C" fn pass_f64_C(x: f64) -> f64 {
14 x
15}
16
17// CHECK: i64 @pass_f32_pair_C(i64 {{[^,]*}})
18#[no_mangle]
19extern "C" fn pass_f32_pair_C(x: (f32, f32)) -> (f32, f32) {
20 x
21}
22
23// CHECK: [2 x i64] @pass_f64_pair_C([2 x i64] {{[^,]*}})
24#[no_mangle]
25extern "C" fn pass_f64_pair_C(x: (f64, f64)) -> (f64, f64) {
26 x
27}
28
29// CHECK: i64 @pass_f64_Rust(i64 {{[^,]*}})
30#[no_mangle]
31fn pass_f64_Rust(x: f64) -> f64 {
32 x
33}
34
35// CHECK: i64 @pass_f32_pair_Rust(i64 {{[^,]*}})
36#[no_mangle]
37fn pass_f32_pair_Rust(x: (f32, f32)) -> (f32, f32) {
38 x
39}
40
41// CHECK: void @pass_f64_pair_Rust(ptr {{.*}}%{{[^ ]+}}, ptr {{.*}}%{{[^ ]+}})
42#[no_mangle]
43fn pass_f64_pair_Rust(x: (f64, f64)) -> (f64, f64) {
44 x
45}
tests/codegen-llvm/sanitizer/kasan-emits-instrumentation.rs+3-1
......@@ -2,9 +2,11 @@
22
33//@ add-minicore
44//@ compile-flags: -Zsanitizer=kernel-address -Copt-level=0
5//@ revisions: aarch64 riscv64imac riscv64gc x86_64
5//@ revisions: aarch64 aarch64v8r riscv64imac riscv64gc x86_64
66//@[aarch64] compile-flags: --target aarch64-unknown-none
77//@[aarch64] needs-llvm-components: aarch64
8//@[aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
9//@[aarch64v8r] needs-llvm-components: aarch64
810//@[riscv64imac] compile-flags: --target riscv64imac-unknown-none-elf
911//@[riscv64imac] needs-llvm-components: riscv
1012//@[riscv64gc] compile-flags: --target riscv64gc-unknown-none-elf
tests/codegen-llvm/sanitizer/kcfi/add-cfi-normalize-integers-flag.rs+3-1
......@@ -1,9 +1,11 @@
11// Verifies that "cfi-normalize-integers" module flag is added.
22//
33//@ add-minicore
4//@ revisions: aarch64 x86_64
4//@ revisions: aarch64 aarch64v8r x86_64
55//@ [aarch64] compile-flags: --target aarch64-unknown-none
66//@ [aarch64] needs-llvm-components: aarch64
7//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
8//@ [aarch64v8r] needs-llvm-components: aarch64
79//@ [x86_64] compile-flags: --target x86_64-unknown-none
810//@ [x86_64] needs-llvm-components: x86
911//@ compile-flags: -Ctarget-feature=-crt-static -Zsanitizer=kcfi -Zsanitizer-cfi-normalize-integers
tests/codegen-llvm/sanitizer/kcfi/add-kcfi-flag.rs+3-1
......@@ -1,9 +1,11 @@
11// Verifies that "kcfi" module flag is added.
22//
33//@ add-minicore
4//@ revisions: aarch64 x86_64
4//@ revisions: aarch64 aarch64v8r x86_64
55//@ [aarch64] compile-flags: --target aarch64-unknown-none
66//@ [aarch64] needs-llvm-components: aarch64
7//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
8//@ [aarch64v8r] needs-llvm-components: aarch64
79//@ [x86_64] compile-flags: --target x86_64-unknown-none
810//@ [x86_64] needs-llvm-components: x86
911//@ compile-flags: -Ctarget-feature=-crt-static -Zsanitizer=kcfi
tests/codegen-llvm/sanitizer/kcfi/add-kcfi-offset-flag.rs+3-1
......@@ -1,9 +1,11 @@
11// Verifies that "kcfi-offset" module flag is added.
22//
33//@ add-minicore
4//@ revisions: aarch64 x86_64
4//@ revisions: aarch64 aarch64v8r x86_64
55//@ [aarch64] compile-flags: --target aarch64-unknown-none
66//@ [aarch64] needs-llvm-components: aarch64
7//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
8//@ [aarch64v8r] needs-llvm-components: aarch64
79//@ [x86_64] compile-flags: --target x86_64-unknown-none
810//@ [x86_64] needs-llvm-components: x86
911//@ compile-flags: -Ctarget-feature=-crt-static -Zsanitizer=kcfi -Z patchable-function-entry=4,3
tests/codegen-llvm/sanitizer/kcfi/emit-kcfi-operand-bundle-attr-sanitize-off.rs+3-1
......@@ -1,9 +1,11 @@
11// Verifies that KCFI operand bundles are omitted.
22//
33//@ add-minicore
4//@ revisions: aarch64 x86_64
4//@ revisions: aarch64 aarch64v8r x86_64
55//@ [aarch64] compile-flags: --target aarch64-unknown-none
66//@ [aarch64] needs-llvm-components: aarch64
7//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
8//@ [aarch64v8r] needs-llvm-components: aarch64
79//@ [x86_64] compile-flags: --target x86_64-unknown-none
810//@ [x86_64] needs-llvm-components: x86
911//@ compile-flags: -Cno-prepopulate-passes -Zsanitizer=kcfi -Copt-level=0
tests/codegen-llvm/sanitizer/kcfi/emit-kcfi-operand-bundle-itanium-cxx-abi-generalized.rs+3-1
......@@ -1,9 +1,11 @@
11// Verifies that generalized KCFI type metadata for functions are emitted.
22//
33//@ add-minicore
4//@ revisions: aarch64 x86_64
4//@ revisions: aarch64 aarch64v8r x86_64
55//@ [aarch64] compile-flags: --target aarch64-unknown-none
66//@ [aarch64] needs-llvm-components: aarch64
7//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
8//@ [aarch64v8r] needs-llvm-components: aarch64
79//@ [x86_64] compile-flags: --target x86_64-unknown-none
810//@ [x86_64] needs-llvm-components: x86
911//@ compile-flags: -Cno-prepopulate-passes -Zsanitizer=kcfi -Zsanitizer-cfi-generalize-pointers
tests/codegen-llvm/sanitizer/kcfi/emit-kcfi-operand-bundle-itanium-cxx-abi-normalized-generalized.rs+3-1
......@@ -1,9 +1,11 @@
11// Verifies that normalized and generalized KCFI type metadata for functions are emitted.
22//
33//@ add-minicore
4//@ revisions: aarch64 x86_64
4//@ revisions: aarch64 aarch64v8r x86_64
55//@ [aarch64] compile-flags: --target aarch64-unknown-none
66//@ [aarch64] needs-llvm-components: aarch64
7//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
8//@ [aarch64v8r] needs-llvm-components: aarch64
79//@ [x86_64] compile-flags: --target x86_64-unknown-none
810//@ [x86_64] needs-llvm-components: x86
911//@ compile-flags: -Cno-prepopulate-passes -Zsanitizer=kcfi -Zsanitizer-cfi-normalize-integers -Zsanitizer-cfi-generalize-pointers
tests/codegen-llvm/sanitizer/kcfi/emit-kcfi-operand-bundle-itanium-cxx-abi-normalized.rs+3-1
......@@ -1,9 +1,11 @@
11// Verifies that normalized KCFI type metadata for functions are emitted.
22//
33//@ add-minicore
4//@ revisions: aarch64 x86_64
4//@ revisions: aarch64 aarch64v8r x86_64
55//@ [aarch64] compile-flags: --target aarch64-unknown-none
66//@ [aarch64] needs-llvm-components: aarch64
7//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
8//@ [aarch64v8r] needs-llvm-components: aarch64
79//@ [x86_64] compile-flags: --target x86_64-unknown-none
810//@ [x86_64] needs-llvm-components: x86
911//@ compile-flags: -Cno-prepopulate-passes -Zsanitizer=kcfi -Zsanitizer-cfi-normalize-integers
tests/codegen-llvm/sanitizer/kcfi/emit-kcfi-operand-bundle-itanium-cxx-abi.rs+3-1
......@@ -1,9 +1,11 @@
11// Verifies that KCFI type metadata for functions are emitted.
22//
33//@ add-minicore
4//@ revisions: aarch64 x86_64
4//@ revisions: aarch64 aarch64v8r x86_64
55//@ [aarch64] compile-flags: --target aarch64-unknown-none
66//@ [aarch64] needs-llvm-components: aarch64
7//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
8//@ [aarch64v8r] needs-llvm-components: aarch64
79//@ [x86_64] compile-flags: --target x86_64-unknown-none
810//@ [x86_64] needs-llvm-components: x86
911//@ compile-flags: -Cno-prepopulate-passes -Zsanitizer=kcfi -Copt-level=0
tests/codegen-llvm/sanitizer/kcfi/emit-kcfi-operand-bundle.rs+3-1
......@@ -1,9 +1,11 @@
11// Verifies that KCFI operand bundles are emitted.
22//
33//@ add-minicore
4//@ revisions: aarch64 x86_64
4//@ revisions: aarch64 aarch64v8r x86_64
55//@ [aarch64] compile-flags: --target aarch64-unknown-none
66//@ [aarch64] needs-llvm-components: aarch64
7//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
8//@ [aarch64v8r] needs-llvm-components: aarch64
79//@ [x86_64] compile-flags: --target x86_64-unknown-none
810//@ [x86_64] needs-llvm-components: x86
911//@ compile-flags: -Cno-prepopulate-passes -Zsanitizer=kcfi -Copt-level=0
tests/codegen-llvm/sanitizer/kcfi/emit-type-metadata-trait-objects.rs+3-1
......@@ -1,9 +1,11 @@
11// Verifies that type metadata identifiers for trait objects are emitted correctly.
22//
33//@ add-minicore
4//@ revisions: aarch64 x86_64
4//@ revisions: aarch64v8r aarch64 x86_64
55//@ [aarch64] compile-flags: --target aarch64-unknown-none
66//@ [aarch64] needs-llvm-components: aarch64
7//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
8//@ [aarch64v8r] needs-llvm-components: aarch64
79//@ [x86_64] compile-flags: --target x86_64-unknown-none
810//@ [x86_64] needs-llvm-components: x86
911//@ compile-flags: -Cno-prepopulate-passes -Zsanitizer=kcfi -Copt-level=0
tests/codegen-llvm/sanitizer/kcfi/fn-ptr-reify-shim.rs+3-1
......@@ -1,7 +1,9 @@
11//@ add-minicore
2//@ revisions: aarch64 x86_64
2//@ revisions: aarch64 aarch64v8r x86_64
33//@ [aarch64] compile-flags: --target aarch64-unknown-none
44//@ [aarch64] needs-llvm-components: aarch64
5//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
6//@ [aarch64v8r] needs-llvm-components: aarch64
57//@ [x86_64] compile-flags: --target x86_64-unknown-none
68//@ [x86_64] needs-llvm-components: x86
79//@ compile-flags: -Ctarget-feature=-crt-static -Zsanitizer=kcfi -Cno-prepopulate-passes -Copt-level=0
tests/codegen-llvm/sanitizer/kcfi/naked-function.rs+3-1
......@@ -1,7 +1,9 @@
11//@ add-minicore
2//@ revisions: aarch64 x86_64
2//@ revisions: aarch64 aarch64v8r x86_64
33//@ [aarch64] compile-flags: --target aarch64-unknown-none
44//@ [aarch64] needs-llvm-components: aarch64
5//@ [aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
6//@ [aarch64v8r] needs-llvm-components: aarch64
57//@ [x86_64] compile-flags: --target x86_64-unknown-none
68//@ [x86_64] needs-llvm-components: x86
79//@ compile-flags: -Ctarget-feature=-crt-static -Zsanitizer=kcfi -Cno-prepopulate-passes -Copt-level=0
tests/codegen-llvm/sanitizer/sanitize-off-asan-kasan.rs+3-1
......@@ -3,9 +3,11 @@
33//
44//@ add-minicore
55//@ compile-flags: -Zsanitizer=kernel-address -Ctarget-feature=-crt-static -Copt-level=0
6//@ revisions: aarch64 riscv64imac riscv64gc x86_64
6//@ revisions: aarch64 aarch64v8r riscv64imac riscv64gc x86_64
77//@[aarch64] compile-flags: --target aarch64-unknown-none
88//@[aarch64] needs-llvm-components: aarch64
9//@[aarch64v8r] compile-flags: --target aarch64v8r-unknown-none
10//@[aarch64v8r] needs-llvm-components: aarch64
911//@[riscv64imac] compile-flags: --target riscv64imac-unknown-none-elf
1012//@[riscv64imac] needs-llvm-components: riscv
1113//@[riscv64gc] compile-flags: --target riscv64gc-unknown-none-elf
tests/run-make/checksum-freshness/binary_file created+1
......@@ -0,0 +1 @@
1binary�
\ No newline at end of file
tests/run-make/checksum-freshness/expected.d+4-2
......@@ -1,6 +1,8 @@
1lib.d: lib.rs foo.rs
1lib.d: lib.rs foo.rs binary_file
22
33lib.rs:
44foo.rs:
5# checksum:blake3=94af75ee4ed805434484c3de51c9025278e5c3ada2315e2592052e102168a503 file_len:120 lib.rs
5binary_file:
6# checksum:blake3=4ac56f3f877798fb762d714c7bcb72e70133f4cc585f80dbd99c07755ae2c7f6 file_len:222 lib.rs
67# checksum:blake3=2720e17bfda4f3b2a5c96bb61b7e76ed8ebe3359b34128c0e5d8032c090a4f1a file_len:119 foo.rs
8# checksum:blake3=119a5db8711914922c5b1c1908be4958175c5afa95c08888de594725329b5439 file_len:7 binary_file
tests/run-make/checksum-freshness/lib.rs+2-1
......@@ -1,7 +1,8 @@
11// A basic library to be used in tests with no real purpose.
22
33mod foo;
4
4// Binary file with invalid UTF-8 sequence.
5static BINARY_FILE: &[u8] = include_bytes!("binary_file");
56pub fn sum(a: i32, b: i32) -> i32 {
67 a + b
78}
tests/rustdoc-ui/doctest/main-alongside-macro-calls.fail.stdout-4
......@@ -13,8 +13,6 @@ error: macros that expand to items must be delimited with braces or followed by
1313 |
1414LL | println!();
1515 | ^^^^^^^^^^
16 |
17 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1816
1917error: macro expansion ignores `{` and any tokens following
2018 --> $SRC_DIR/std/src/macros.rs:LL:COL
......@@ -35,8 +33,6 @@ error: macros that expand to items must be delimited with braces or followed by
3533 |
3634LL | println!();
3735 | ^^^^^^^^^^
38 |
39 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
4036
4137error: macro expansion ignores `{` and any tokens following
4238 --> $SRC_DIR/std/src/macros.rs:LL:COL
tests/ui/asm/aarch64/type-check-2.stderr-1
......@@ -21,7 +21,6 @@ LL | asm!("{}", in(reg) vec![0]);
2121 | ^^^^^^^
2222 |
2323 = note: only integers, floats, SIMD vectors, pointers and function pointers can be used as arguments for inline assembly
24 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
2524
2625error: cannot use value of type `(i32, i32, i32)` for inline assembly
2726 --> $DIR/type-check-2.rs:36:28
tests/ui/asm/aarch64v8r.rs created+140
......@@ -0,0 +1,140 @@
1// Codegen test of mandatory Armv8-R AArch64 extensions
2
3//@ add-minicore
4//@ revisions: hf sf
5//@ [hf] compile-flags: --target aarch64v8r-unknown-none
6//@ [hf] needs-llvm-components: aarch64
7//@ [sf] compile-flags: --target aarch64v8r-unknown-none-softfloat
8//@ [sf] needs-llvm-components: aarch64
9//@ build-pass
10//@ ignore-backends: gcc
11
12#![feature(no_core)]
13#![no_core]
14#![no_main]
15#![crate_type = "rlib"]
16#![deny(dead_code)] // ensures we call all private functions from the public one
17
18extern crate minicore;
19use minicore::*;
20
21/* # Mandatory extensions
22 *
23 * A comment indicates that the extension has no associated assembly instruction and cannot be
24 * codegen tested
25 *
26 * ## References:
27 *
28 * - Arm Architecture Reference Manual for R-profile AArch64 architecture (DDI 0628) -- has the
29 * list of mandatory extensions
30 * - Arm Architecture Reference Manual for A-profile architecture (ARM DDI 0487) -- has the
31 * mapping from features to instructions
32 * - Feature names in A-profile architecture (109697_0100_02_en Version 1.0) -- overview of
33 * what each extension mean
34 * */
35pub fn mandatory_extensions() {
36 /* ## ARMv8.0 */
37 feat_aa64();
38 // FEAT_AA64EL0
39 // FEAT_AA64EL1
40 // FEAT_AA64EL2
41 feat_crc32();
42 // FEAT_EL0
43 // FEAT_EL1
44 // FEAT_EL2
45 // FEAT_IVIPT
46
47 /* ## ARMv8.1 */
48 // FEAT_HPDS
49 feat_lse();
50 feat_pan();
51
52 /* ## ARMv8.2 */
53 feat_asmv8p2();
54 feat_dpb();
55 // FEAT_Debugv8p2
56 // FEAT_PAN2
57 feat_ras();
58 // FEAT_TTCNP
59 feat_uao();
60 // FEAT_XNX
61
62 /* ## ARMv8.3 */
63 feat_lrcpc();
64 feat_pauth();
65
66 /* ## ARMv8.4 */
67 feat_dit();
68 // FEAT_Debugv8p4
69 feat_flagm();
70 // FEAT_IDST
71 feat_lrcpc2();
72 // FEAT_LSE2
73 // FEAT_S2FWB
74 feat_tlbios();
75 feat_tlbirange();
76 // FEAT_TTL
77}
78
79fn feat_aa64() {
80 // CurrentEL register only present when FEAT_AA64 is implemented
81 unsafe { asm!("mrs x0, CurrentEL") }
82}
83
84fn feat_crc32() {
85 // instruction is present when FEAT_CRC32 is implemented
86 unsafe { asm!("crc32b w0, w1, w2") }
87}
88
89fn feat_lse() {
90 // instruction is present when FEAT_LSE is implemented
91 unsafe { asm!("casp w0, w1, w2, w3, [x4]") }
92}
93
94fn feat_pan() {
95 unsafe { asm!("mrs x0, PAN") }
96}
97
98fn feat_asmv8p2() {
99 unsafe { asm!("BFC w0, #0, #1") }
100}
101
102fn feat_dpb() {
103 unsafe { asm!("DC CVAP, x0") }
104}
105
106fn feat_ras() {
107 unsafe { asm!("ESB") }
108}
109
110fn feat_uao() {
111 unsafe { asm!("mrs x0, UAO") }
112}
113
114fn feat_lrcpc() {
115 unsafe { asm!("ldaprb w0, [x1]") }
116}
117
118fn feat_pauth() {
119 unsafe { asm!("xpacd x0") }
120}
121
122fn feat_dit() {
123 unsafe { asm!("mrs x0, DIT") }
124}
125
126fn feat_flagm() {
127 unsafe { asm!("cfinv") }
128}
129
130fn feat_lrcpc2() {
131 unsafe { asm!("stlurb w0, [x1]") }
132}
133
134fn feat_tlbios() {
135 unsafe { asm!("tlbi VMALLE1OS") }
136}
137
138fn feat_tlbirange() {
139 unsafe { asm!("tlbi RVAE1IS, x0") }
140}
tests/ui/asm/parse-error.stderr-8
......@@ -193,16 +193,12 @@ error: asm template must be a string literal
193193 |
194194LL | asm!(format!("{{{}}}", 0), in(reg) foo);
195195 | ^^^^^^^^^^^^^^^^^^^^
196 |
197 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
198196
199197error: asm template must be a string literal
200198 --> $DIR/parse-error.rs:86:21
201199 |
202200LL | asm!("{1}", format!("{{{}}}", 0), in(reg) foo, out(reg) bar);
203201 | ^^^^^^^^^^^^^^^^^^^^
204 |
205 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
206202
207203error: _ cannot be used for input operands
208204 --> $DIR/parse-error.rs:88:28
......@@ -357,16 +353,12 @@ error: asm template must be a string literal
357353 |
358354LL | global_asm!(format!("{{{}}}", 0), const FOO);
359355 | ^^^^^^^^^^^^^^^^^^^^
360 |
361 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
362356
363357error: asm template must be a string literal
364358 --> $DIR/parse-error.rs:143:20
365359 |
366360LL | global_asm!("{1}", format!("{{{}}}", 0), const FOO, const BAR);
367361 | ^^^^^^^^^^^^^^^^^^^^
368 |
369 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
370362
371363error: the `in` operand cannot be used with `global_asm!`
372364 --> $DIR/parse-error.rs:146:19
tests/ui/asm/x86_64/type-check-2.stderr-1
......@@ -21,7 +21,6 @@ LL | asm!("{}", in(reg) vec![0]);
2121 | ^^^^^^^
2222 |
2323 = note: only integers, floats, SIMD vectors, pointers and function pointers can be used as arguments for inline assembly
24 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
2524
2625error: cannot use value of type `(i32, i32, i32)` for inline assembly
2726 --> $DIR/type-check-2.rs:52:28
tests/ui/associated-consts/defaults-not-assumed-fail.stderr-3
......@@ -23,8 +23,6 @@ note: erroneous constant encountered
2323 |
2424LL | assert_eq!(<() as Tr>::B, 0); // causes the error above
2525 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
26 |
27 = note: this note originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
2826
2927note: erroneous constant encountered
3028 --> $DIR/defaults-not-assumed-fail.rs:34:5
......@@ -33,7 +31,6 @@ LL | assert_eq!(<() as Tr>::B, 0); // causes the error above
3331 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3432 |
3533 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
36 = note: this note originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
3734
3835error: aborting due to 1 previous error
3936
tests/ui/async-await/unreachable-lint-2.stderr-1
......@@ -11,7 +11,6 @@ note: the lint level is defined here
1111 |
1212LL | #![deny(unreachable_code)]
1313 | ^^^^^^^^^^^^^^^^
14 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615error: aborting due to 1 previous error
1716
tests/ui/binop/binary-operation-error-on-function-70724.stderr-4
......@@ -6,8 +6,6 @@ LL | assert_eq!(a, 0);
66 | |
77 | fn() -> i32 {a}
88 | {integer}
9 |
10 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
119
1210error[E0308]: mismatched types
1311 --> $DIR/binary-operation-error-on-function-70724.rs:7:5
......@@ -17,7 +15,6 @@ LL | assert_eq!(a, 0);
1715 |
1816 = note: expected fn item `fn() -> i32 {a}`
1917 found type `{integer}`
20 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
2118
2219error[E0277]: `fn() -> i32 {a}` doesn't implement `Debug`
2320 --> $DIR/binary-operation-error-on-function-70724.rs:7:5
......@@ -29,7 +26,6 @@ LL | assert_eq!(a, 0);
2926 | ^^^^^^^^^^^^^^^^ the trait `Debug` is not implemented for fn item `fn() -> i32 {a}`
3027 |
3128 = help: use parentheses to call this function: `a()`
32 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
3329
3430error: aborting due to 3 previous errors
3531
tests/ui/binop/eq-vec.stderr-1
......@@ -12,7 +12,6 @@ note: an implementation of `PartialEq` might be missing for `Foo`
1212 |
1313LL | enum Foo {
1414 | ^^^^^^^^ must implement `PartialEq`
15 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
1615help: consider annotating `Foo` with `#[derive(PartialEq)]`
1716 |
1817LL + #[derive(PartialEq)]
tests/ui/binop/function-comparison-errors-59488.stderr-6
......@@ -80,24 +80,18 @@ LL | assert_eq!(Foo::Bar, i);
8080 | |
8181 | fn(usize) -> Foo {Foo::Bar}
8282 | fn(usize) -> Foo {Foo::Bar}
83 |
84 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
8583
8684error[E0277]: `fn(usize) -> Foo {Foo::Bar}` doesn't implement `Debug`
8785 --> $DIR/function-comparison-errors-59488.rs:31:5
8886 |
8987LL | assert_eq!(Foo::Bar, i);
9088 | ^^^^^^^^^^^^^^^^^^^^^^^ the trait `Debug` is not implemented for fn item `fn(usize) -> Foo {Foo::Bar}`
91 |
92 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
9389
9490error[E0277]: `fn(usize) -> Foo {Foo::Bar}` doesn't implement `Debug`
9591 --> $DIR/function-comparison-errors-59488.rs:31:5
9692 |
9793LL | assert_eq!(Foo::Bar, i);
9894 | ^^^^^^^^^^^^^^^^^^^^^^^ the trait `Debug` is not implemented for fn item `fn(usize) -> Foo {Foo::Bar}`
99 |
100 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
10195
10296error: aborting due to 10 previous errors
10397
tests/ui/binop/issue-77910-1.stderr-3
......@@ -6,8 +6,6 @@ LL | assert_eq!(foo, y);
66 | |
77 | for<'a> fn(&'a i32) -> &'a i32 {foo}
88 | _
9 |
10 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
119
1210error[E0277]: `for<'a> fn(&'a i32) -> &'a i32 {foo}` doesn't implement `Debug`
1311 --> $DIR/issue-77910-1.rs:8:5
......@@ -19,7 +17,6 @@ LL | assert_eq!(foo, y);
1917 | ^^^^^^^^^^^^^^^^^^ the trait `Debug` is not implemented for fn item `for<'a> fn(&'a i32) -> &'a i32 {foo}`
2018 |
2119 = help: use parentheses to call this function: `foo(/* &i32 */)`
22 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
2320
2421error[E0381]: used binding `xs` isn't initialized
2522 --> $DIR/issue-77910-1.rs:3:5
tests/ui/borrowck/alias-liveness/higher-ranked-outlives-for-capture.stderr-2
......@@ -8,8 +8,6 @@ LL | test(&vec![])
88 | argument requires that borrow lasts for `'static`
99LL | }
1010 | - temporary value is freed at the end of this statement
11 |
12 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
1311
1412error: aborting due to 1 previous error
1513
tests/ui/borrowck/borrowck-and-init.stderr-2
......@@ -8,8 +8,6 @@ LL | println!("{}", false && { i = 5; true });
88 | ----- binding initialized here in some conditions
99LL | println!("{}", i);
1010 | ^ `i` used here but it is possibly-uninitialized
11 |
12 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1311
1412error: aborting due to 1 previous error
1513
tests/ui/borrowck/borrowck-borrowed-uniq-rvalue-2.stderr-1
......@@ -8,7 +8,6 @@ LL | let x = defer(&vec!["Goodbye", "world!"]);
88LL | x.x[0];
99 | ------ borrow later used here
1010 |
11 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
1211help: consider using a `let` binding to create a longer lived value
1312 |
1413LL ~ let binding = vec!["Goodbye", "world!"];
tests/ui/borrowck/borrowck-break-uninit-2.stderr-1
......@@ -7,7 +7,6 @@ LL | let x: isize;
77LL | println!("{}", x);
88 | ^ `x` used here but it isn't initialized
99 |
10 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1110help: consider assigning a value
1211 |
1312LL | let x: isize = 42;
tests/ui/borrowck/borrowck-break-uninit.stderr-1
......@@ -7,7 +7,6 @@ LL | let x: isize;
77LL | println!("{}", x);
88 | ^ `x` used here but it isn't initialized
99 |
10 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1110help: consider assigning a value
1211 |
1312LL | let x: isize = 42;
tests/ui/borrowck/borrowck-or-init.stderr-2
......@@ -8,8 +8,6 @@ LL | println!("{}", false || { i = 5; true });
88 | ----- binding initialized here in some conditions
99LL | println!("{}", i);
1010 | ^ `i` used here but it is possibly-uninitialized
11 |
12 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1311
1412error: aborting due to 1 previous error
1513
tests/ui/borrowck/borrowck-while-break.stderr-2
......@@ -8,8 +8,6 @@ LL | while cond {
88...
99LL | println!("{}", v);
1010 | ^ `v` used here but it is possibly-uninitialized
11 |
12 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1311
1412error: aborting due to 1 previous error
1513
tests/ui/borrowck/issue-24267-flow-exit.stderr-2
......@@ -7,7 +7,6 @@ LL | loop { x = break; }
77LL | println!("{}", x);
88 | ^ `x` used here but it isn't initialized
99 |
10 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1110help: consider assigning a value
1211 |
1312LL | let x: i32 = 42;
......@@ -22,7 +21,6 @@ LL | for _ in 0..10 { x = continue; }
2221LL | println!("{}", x);
2322 | ^ `x` used here but it isn't initialized
2423 |
25 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2624help: consider assigning a value
2725 |
2826LL | let x: i32 = 42;
tests/ui/borrowck/issue-47646.stderr-2
......@@ -12,8 +12,6 @@ LL | println!("{:?}", heap);
1212...
1313LL | };
1414 | - ... and the mutable borrow might be used here, when that temporary is dropped and runs the destructor for type `(Option<std::collections::binary_heap::PeekMut<'_, i32>>, ())`
15 |
16 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1715
1816error: aborting due to 1 previous error
1917
tests/ui/borrowck/issue-64453.stderr-1
......@@ -8,7 +8,6 @@ note: function `format` is not const
88 --> $SRC_DIR/alloc/src/fmt.rs:LL:COL
99 = note: calls in statics are limited to constant functions, tuple structs and tuple variants
1010 = note: consider wrapping this expression in `std::sync::LazyLock::new(|| ...)`
11 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
1211
1312error[E0507]: cannot move out of static item `settings_dir`
1413 --> $DIR/issue-64453.rs:13:37
tests/ui/borrowck/ownership-struct-update-moved-error.stderr-1
......@@ -13,7 +13,6 @@ note: `Mine::make_string_bar` takes ownership of the receiver `self`, which move
1313 |
1414LL | fn make_string_bar(mut self) -> Mine {
1515 | ^^^^
16 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1716
1817error: aborting due to 1 previous error
1918
tests/ui/borrowck/suggest-assign-rvalue.stderr-10
......@@ -19,7 +19,6 @@ LL | let my_float: f32;
1919LL | println!("my_float: {}", my_float);
2020 | ^^^^^^^^ `my_float` used here but it isn't initialized
2121 |
22 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2322help: consider assigning a value
2423 |
2524LL | let my_float: f32 = 3.14159;
......@@ -33,7 +32,6 @@ LL | let demo: Demo;
3332LL | println!("demo: {:?}", demo);
3433 | ^^^^ `demo` used here but it isn't initialized
3534 |
36 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
3735help: consider assigning a value
3836 |
3937LL | let demo: Demo = Default::default();
......@@ -47,7 +45,6 @@ LL | let demo_no: DemoNoDef;
4745LL | println!("demo_no: {:?}", demo_no);
4846 | ^^^^^^^ `demo_no` used here but it isn't initialized
4947 |
50 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
5148help: consider assigning a value
5249 |
5350LL | let demo_no: DemoNoDef = /* value */;
......@@ -61,7 +58,6 @@ LL | let arr: [i32; 5];
6158LL | println!("arr: {:?}", arr);
6259 | ^^^ `arr` used here but it isn't initialized
6360 |
64 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
6561help: consider assigning a value
6662 |
6763LL | let arr: [i32; 5] = [42; 5];
......@@ -75,7 +71,6 @@ LL | let foo: Vec<&str>;
7571LL | println!("foo: {:?}", foo);
7672 | ^^^ `foo` used here but it isn't initialized
7773 |
78 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
7974help: consider assigning a value
8075 |
8176LL | let foo: Vec<&str> = vec![];
......@@ -89,7 +84,6 @@ LL | let my_string: String;
8984LL | println!("my_string: {}", my_string);
9085 | ^^^^^^^^^ `my_string` used here but it isn't initialized
9186 |
92 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
9387help: consider assigning a value
9488 |
9589LL | let my_string: String = Default::default();
......@@ -103,7 +97,6 @@ LL | let my_int: &i32;
10397LL | println!("my_int: {}", *my_int);
10498 | ^^^^^^^ `*my_int` used here but it isn't initialized
10599 |
106 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
107100help: consider assigning a value
108101 |
109102LL | let my_int: &i32 = &42;
......@@ -117,7 +110,6 @@ LL | let hello: &str;
117110LL | println!("hello: {}", hello);
118111 | ^^^^^ `hello` used here but it isn't initialized
119112 |
120 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
121113help: consider assigning a value
122114 |
123115LL | let hello: &str = "";
......@@ -130,8 +122,6 @@ LL | let never: !;
130122 | ----- binding declared here but left uninitialized
131123LL | println!("never: {}", never);
132124 | ^^^^^ `never` used here but it isn't initialized
133 |
134 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
135125
136126error: aborting due to 10 previous errors
137127
tests/ui/closures/2229_closure_analysis/diagnostics/arrays.stderr-2
......@@ -53,8 +53,6 @@ LL | println!("{}", arr[3]);
5353...
5454LL | c();
5555 | - mutable borrow later used here
56 |
57 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
5856
5957error[E0502]: cannot borrow `arr` as immutable because it is also borrowed as mutable
6058 --> $DIR/arrays.rs:71:24
tests/ui/closures/2229_closure_analysis/diagnostics/box.stderr-2
......@@ -25,8 +25,6 @@ LL | println!("{}", e.0.0.m.x);
2525LL |
2626LL | c();
2727 | - mutable borrow later used here
28 |
29 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
3028
3129error[E0506]: cannot assign to `e.0.0.m.x` because it is borrowed
3230 --> $DIR/box.rs:55:5
tests/ui/closures/2229_closure_analysis/diagnostics/repr_packed.stderr-1
......@@ -7,7 +7,6 @@ LL | println!("{}", foo.x);
77 = note: this struct is 1-byte aligned, but the type of this field may require higher alignment
88 = note: creating a misaligned reference is undefined behavior (even if that reference is never dereferenced)
99 = help: copy the field contents to a local variable, or replace the reference with a raw pointer and use `read_unaligned`/`write_unaligned` (loads and stores via `*p` must be properly aligned even when using raw pointers)
10 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1110
1211error: aborting due to 1 previous error
1312
tests/ui/closures/2229_closure_analysis/diagnostics/simple-struct-min-capture.stderr-2
......@@ -13,8 +13,6 @@ LL | println!("{:?}", p);
1313LL |
1414LL | c();
1515 | - mutable borrow later used here
16 |
17 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1816
1917error: aborting due to 1 previous error
2018
tests/ui/closures/issue-111932.stderr-1
......@@ -17,7 +17,6 @@ LL | println!("{:?}", foo);
1717 | required by this formatting parameter
1818 |
1919 = help: the trait `Sized` is not implemented for `dyn Foo`
20 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2120
2221error: aborting due to 2 previous errors
2322
tests/ui/codemap_tests/bad-format-args.stderr-2
......@@ -3,8 +3,6 @@ error: requires at least a format string argument
33 |
44LL | format!();
55 | ^^^^^^^^^
6 |
7 = note: this error originates in the macro `$crate::__export::format_args` which comes from the expansion of the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
86
97error: expected `,`, found `1`
108 --> $DIR/bad-format-args.rs:3:16
tests/ui/codemap_tests/tab_3.stderr-1
......@@ -11,7 +11,6 @@ LL | println!("{:?}", some_vec);
1111 |
1212note: `into_iter` takes ownership of the receiver `self`, which moves `some_vec`
1313 --> $SRC_DIR/core/src/iter/traits/collect.rs:LL:COL
14 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1514help: you can `clone` the value and consume it, but this might not be your desired behavior
1615 |
1716LL | some_vec.clone().into_iter();
tests/ui/const-generics/vec-macro-in-static-array.stderr-1
......@@ -6,7 +6,6 @@ LL | static VEC: [u32; 256] = vec![];
66 |
77 = note: expected array `[u32; 256]`
88 found struct `Vec<_>`
9 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
109
1110error: aborting due to 1 previous error
1211
tests/ui/consts/const-eval/const_panic.stderr-4
......@@ -21,8 +21,6 @@ error[E0080]: evaluation panicked: not implemented
2121 |
2222LL | const X: () = std::unimplemented!();
2323 | ^^^^^^^^^^^^^^^^^^^^^ evaluation of `X` failed here
24 |
25 = note: this error originates in the macro `std::unimplemented` (in Nightly builds, run with -Z macro-backtrace for more info)
2624
2725error[E0080]: evaluation panicked: hello
2826 --> $DIR/const_panic.rs:19:15
......@@ -59,8 +57,6 @@ error[E0080]: evaluation panicked: not implemented
5957 |
6058LL | const X_CORE: () = core::unimplemented!();
6159 | ^^^^^^^^^^^^^^^^^^^^^^ evaluation of `X_CORE` failed here
62 |
63 = note: this error originates in the macro `core::unimplemented` (in Nightly builds, run with -Z macro-backtrace for more info)
6460
6561error[E0080]: evaluation panicked: hello
6662 --> $DIR/const_panic.rs:37:20
tests/ui/consts/const-eval/const_panic_2021.stderr-4
......@@ -21,8 +21,6 @@ error[E0080]: evaluation panicked: not implemented
2121 |
2222LL | const D: () = std::unimplemented!();
2323 | ^^^^^^^^^^^^^^^^^^^^^ evaluation of `D` failed here
24 |
25 = note: this error originates in the macro `std::unimplemented` (in Nightly builds, run with -Z macro-backtrace for more info)
2624
2725error[E0080]: evaluation panicked: hello
2826 --> $DIR/const_panic_2021.rs:18:15
......@@ -53,8 +51,6 @@ error[E0080]: evaluation panicked: not implemented
5351 |
5452LL | const D_CORE: () = core::unimplemented!();
5553 | ^^^^^^^^^^^^^^^^^^^^^^ evaluation of `D_CORE` failed here
56 |
57 = note: this error originates in the macro `core::unimplemented` (in Nightly builds, run with -Z macro-backtrace for more info)
5854
5955error[E0080]: evaluation panicked: hello
6056 --> $DIR/const_panic_2021.rs:33:20
tests/ui/consts/const-eval/const_panic_libcore_bin.stderr-2
......@@ -15,8 +15,6 @@ error[E0080]: evaluation panicked: not implemented
1515 |
1616LL | const X: () = unimplemented!();
1717 | ^^^^^^^^^^^^^^^^ evaluation of `X` failed here
18 |
19 = note: this error originates in the macro `unimplemented` (in Nightly builds, run with -Z macro-backtrace for more info)
2018
2119error: aborting due to 3 previous errors
2220
tests/ui/consts/const-eval/format.stderr-2
......@@ -13,7 +13,6 @@ LL | println!("{:?}", 0);
1313 | ^^^^^^^^^^^^^^^^^^^
1414 |
1515 = note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
16 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1716
1817error[E0015]: cannot call non-const function `std::io::_print` in constant functions
1918 --> $DIR/format.rs:7:5
......@@ -24,7 +23,6 @@ LL | println!("{:?}", 0);
2423note: function `_print` is not const
2524 --> $SRC_DIR/std/src/io/stdio.rs:LL:COL
2625 = note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
27 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2826
2927error[E0015]: cannot call non-const formatting macro in constant functions
3028 --> $DIR/format.rs:13:5
tests/ui/consts/const-eval/issue-44578.stderr-3
......@@ -23,8 +23,6 @@ note: erroneous constant encountered
2323 |
2424LL | println!("{}", <Bar<u16, u8> as Foo>::AMT);
2525 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
26 |
27 = note: this note originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2826
2927note: erroneous constant encountered
3028 --> $DIR/issue-44578.rs:26:20
......@@ -33,7 +31,6 @@ LL | println!("{}", <Bar<u16, u8> as Foo>::AMT);
3331 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
3432 |
3533 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
36 = note: this note originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
3734
3835error: aborting due to 1 previous error
3936
tests/ui/consts/control-flow/issue-50577.stderr-2
......@@ -3,8 +3,6 @@ error[E0308]: mismatched types
33 |
44LL | Drop = assert_eq!(1, 1),
55 | ^^^^^^^^^^^^^^^^ expected `isize`, found `()`
6 |
7 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
86
97error: aborting due to 1 previous error
108
tests/ui/consts/min_const_fn/bad_const_fn_body_ice.stderr-3
......@@ -3,8 +3,6 @@ error[E0010]: allocations are not allowed in constant functions
33 |
44LL | vec![1, 2, 3]
55 | ^^^^^^^^^^^^^ allocation not allowed in constant functions
6 |
7 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
86
97error[E0015]: cannot call non-const method `slice::<impl [i32]>::into_vec::<std::alloc::Global>` in constant functions
108 --> $DIR/bad_const_fn_body_ice.rs:2:5
......@@ -13,7 +11,6 @@ LL | vec![1, 2, 3]
1311 | ^^^^^^^^^^^^^
1412 |
1513 = note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
16 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
1714
1815error: aborting due to 2 previous errors
1916
tests/ui/consts/recursive-const-in-impl.stderr-1
......@@ -6,7 +6,6 @@ LL | println!("{}", Thing::<i32>::X);
66 |
77 = help: consider increasing the recursion limit by adding a `#![recursion_limit = "14"]` attribute to your crate (`recursive_const_in_impl`)
88 = note: query depth increased by 9 when simplifying constant for the type system `main::promoted[0]`
9 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
109
1110error: aborting due to 1 previous error
1211
tests/ui/coroutine/yield-while-ref-reborrowed.stderr-2
......@@ -10,8 +10,6 @@ LL | println!("{}", x);
1010 | ^ second borrow occurs here
1111LL | Pin::new(&mut b).resume(());
1212 | ------ first borrow later used here
13 |
14 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1513
1614error: aborting due to 1 previous error
1715
tests/ui/delegation/ice-line-bounds-issue-148732.stderr-3
......@@ -3,8 +3,6 @@ error[E0106]: missing lifetime specifier
33 |
44LL | dbg!(b);
55 | ^^^^^^^ expected named lifetime parameter
6 |
7 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
86
97error[E0425]: cannot find function `a` in this scope
108 --> $DIR/ice-line-bounds-issue-148732.rs:1:7
......@@ -37,7 +35,6 @@ LL | dbg!(b);
3735 | ^^^^^^^ the trait `Debug` is not implemented for fn item `fn() {b}`
3836 |
3937 = help: use parentheses to call this function: `b()`
40 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
4138
4239error: aborting due to 4 previous errors
4340
tests/ui/derives/nonsense-input-to-debug.stderr-2
......@@ -13,8 +13,6 @@ LL | should_be_vec_t: vec![T],
1313 | expected type
1414 | in this macro invocation
1515 | this macro call doesn't expand to a type
16 |
17 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
1816
1917error[E0392]: type parameter `T` is never used
2018 --> $DIR/nonsense-input-to-debug.rs:5:17
tests/ui/error-codes/E0010-teach.stderr-2
......@@ -5,7 +5,6 @@ LL | const CON: Vec<i32> = vec![1, 2, 3];
55 | ^^^^^^^^^^^^^ allocation not allowed in constants
66 |
77 = note: The runtime heap is not yet available at compile-time, so no runtime heap allocations can be created.
8 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
98
109error[E0015]: cannot call non-const method `slice::<impl [i32]>::into_vec::<std::alloc::Global>` in constants
1110 --> $DIR/E0010-teach.rs:5:23
......@@ -14,7 +13,6 @@ LL | const CON: Vec<i32> = vec![1, 2, 3];
1413 | ^^^^^^^^^^^^^
1514 |
1615 = note: calls in constants are limited to constant functions, tuple structs and tuple variants
17 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
1816
1917error: aborting due to 2 previous errors
2018
tests/ui/error-codes/E0010.stderr-3
......@@ -3,8 +3,6 @@ error[E0010]: allocations are not allowed in constants
33 |
44LL | const CON: Vec<i32> = vec![1, 2, 3];
55 | ^^^^^^^^^^^^^ allocation not allowed in constants
6 |
7 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
86
97error[E0015]: cannot call non-const method `slice::<impl [i32]>::into_vec::<std::alloc::Global>` in constants
108 --> $DIR/E0010.rs:3:23
......@@ -13,7 +11,6 @@ LL | const CON: Vec<i32> = vec![1, 2, 3];
1311 | ^^^^^^^^^^^^^
1412 |
1513 = note: calls in constants are limited to constant functions, tuple structs and tuple variants
16 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
1714
1815error: aborting due to 2 previous errors
1916
tests/ui/errors/span-format_args-issue-140578.stderr-10
......@@ -3,40 +3,30 @@ error[E0282]: type annotations needed
33 |
44LL | print!("{:?} {a} {a:?}", [], a = 1 + 1);
55 | ^^ cannot infer type
6 |
7 = note: this error originates in the macro `$crate::format_args` which comes from the expansion of the macro `print` (in Nightly builds, run with -Z macro-backtrace for more info)
86
97error[E0282]: type annotations needed
108 --> $DIR/span-format_args-issue-140578.rs:7:30
119 |
1210LL | println!("{:?} {a} {a:?}", [], a = 1 + 1);
1311 | ^^ cannot infer type
14 |
15 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1612
1713error[E0282]: type annotations needed
1814 --> $DIR/span-format_args-issue-140578.rs:12:35
1915 |
2016LL | println!("{:?} {:?} {a} {a:?}", [], [], a = 1 + 1);
2117 | ^^ cannot infer type
22 |
23 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2418
2519error[E0282]: type annotations needed
2620 --> $DIR/span-format_args-issue-140578.rs:17:41
2721 |
2822LL | println!("{:?} {:?} {a} {a:?} {b:?}", [], [], a = 1 + 1, b = []);
2923 | ^^ cannot infer type
30 |
31 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
3224
3325error[E0282]: type annotations needed
3426 --> $DIR/span-format_args-issue-140578.rs:26:9
3527 |
3628LL | [],
3729 | ^^ cannot infer type
38 |
39 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
4030
4131error: aborting due to 5 previous errors
4232
tests/ui/expr/if/assert-macro-without-else.stderr-4
......@@ -11,16 +11,12 @@ error[E0308]: mismatched types
1111 |
1212LL | assert_eq!(1, 1)
1313 | ^^^^^^^^^^^^^^^^ expected `i32`, found `()`
14 |
15 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
1614
1715error[E0308]: mismatched types
1816 --> $DIR/assert-macro-without-else.rs:14:5
1917 |
2018LL | assert_ne!(1, 2)
2119 | ^^^^^^^^^^^^^^^^ expected `bool`, found `()`
22 |
23 = note: this error originates in the macro `assert_ne` (in Nightly builds, run with -Z macro-backtrace for more info)
2420
2521error[E0308]: mismatched types
2622 --> $DIR/assert-macro-without-else.rs:26:9
tests/ui/feature-gates/feature-gate-global-registration.stderr-2
......@@ -6,8 +6,6 @@ LL | todo!();
66 | |
77 | expected one of `!` or `::`
88 | in this macro invocation
9 |
10 = note: this error originates in the macro `todo` (in Nightly builds, run with -Z macro-backtrace for more info)
119
1210error: aborting due to 1 previous error
1311
tests/ui/fmt/format-args-argument-span.stderr-4
......@@ -6,7 +6,6 @@ LL | println!("{x:?} {x} {x:?}");
66 |
77 = help: the trait `std::fmt::Display` is not implemented for `Option<{integer}>`
88 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
9 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
109
1110error[E0277]: `Option<{integer}>` doesn't implement `std::fmt::Display`
1211 --> $DIR/format-args-argument-span.rs:15:37
......@@ -18,7 +17,6 @@ LL | println!("{x:?} {x} {x:?}", x = Some(1));
1817 |
1918 = help: the trait `std::fmt::Display` is not implemented for `Option<{integer}>`
2019 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
21 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2220
2321error[E0277]: `DisplayOnly` doesn't implement `Debug`
2422 --> $DIR/format-args-argument-span.rs:18:19
......@@ -28,7 +26,6 @@ LL | println!("{x} {x:?} {x}");
2826 |
2927 = help: the trait `Debug` is not implemented for `DisplayOnly`
3028 = note: add `#[derive(Debug)]` to `DisplayOnly` or manually `impl Debug for DisplayOnly`
31 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
3229help: consider annotating `DisplayOnly` with `#[derive(Debug)]`
3330 |
3431LL + #[derive(Debug)]
......@@ -45,7 +42,6 @@ LL | println!("{x} {x:?} {x}", x = DisplayOnly);
4542 |
4643 = help: the trait `Debug` is not implemented for `DisplayOnly`
4744 = note: add `#[derive(Debug)]` to `DisplayOnly` or manually `impl Debug for DisplayOnly`
48 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
4945help: consider annotating `DisplayOnly` with `#[derive(Debug)]`
5046 |
5147LL + #[derive(Debug)]
tests/ui/fmt/ifmt-bad-arg.stderr-2
......@@ -320,7 +320,6 @@ LL | println!("{} {:.*} {}", 1, 3.2, 4);
320320 found reference `&{float}`
321321note: associated function defined here
322322 --> $SRC_DIR/core/src/fmt/rt.rs:LL:COL
323 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
324323
325324error[E0308]: mismatched types
326325 --> $DIR/ifmt-bad-arg.rs:81:35
......@@ -334,7 +333,6 @@ LL | println!("{} {:07$.*} {}", 1, 3.2, 4);
334333 found reference `&{float}`
335334note: associated function defined here
336335 --> $SRC_DIR/core/src/fmt/rt.rs:LL:COL
337 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
338336
339337error: aborting due to 38 previous errors
340338
tests/ui/fmt/ifmt-unimpl.stderr-1
......@@ -17,7 +17,6 @@ LL | format!("{:X}", "3");
1717 i32
1818 and 9 others
1919 = note: required for `&str` to implement `UpperHex`
20 = note: this error originates in the macro `$crate::__export::format_args` which comes from the expansion of the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
2120
2221error: aborting due to 1 previous error
2322
tests/ui/fmt/non-source-literals.stderr-4
......@@ -10,7 +10,6 @@ help: the trait `std::fmt::Display` is not implemented for `NonDisplay`
1010LL | pub struct NonDisplay;
1111 | ^^^^^^^^^^^^^^^^^^^^^
1212 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
13 = note: this error originates in the macro `$crate::__export::format_args` which comes from the expansion of the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
1413
1514error[E0277]: `NonDisplay` doesn't implement `std::fmt::Display`
1615 --> $DIR/non-source-literals.rs:10:45
......@@ -24,7 +23,6 @@ help: the trait `std::fmt::Display` is not implemented for `NonDisplay`
2423LL | pub struct NonDisplay;
2524 | ^^^^^^^^^^^^^^^^^^^^^
2625 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
27 = note: this error originates in the macro `$crate::__export::format_args` which comes from the expansion of the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
2826
2927error[E0277]: `NonDebug` doesn't implement `Debug`
3028 --> $DIR/non-source-literals.rs:11:42
......@@ -34,7 +32,6 @@ LL | let _ = format!(concat!("{:", "?}"), NonDebug);
3432 |
3533 = help: the trait `Debug` is not implemented for `NonDebug`
3634 = note: add `#[derive(Debug)]` to `NonDebug` or manually `impl Debug for NonDebug`
37 = note: this error originates in the macro `$crate::__export::format_args` which comes from the expansion of the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
3835help: consider annotating `NonDebug` with `#[derive(Debug)]`
3936 |
4037LL + #[derive(Debug)]
......@@ -49,7 +46,6 @@ LL | let _ = format!(concat!("{", "0", ":?}"), NonDebug);
4946 |
5047 = help: the trait `Debug` is not implemented for `NonDebug`
5148 = note: add `#[derive(Debug)]` to `NonDebug` or manually `impl Debug for NonDebug`
52 = note: this error originates in the macro `$crate::__export::format_args` which comes from the expansion of the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
5349help: consider annotating `NonDebug` with `#[derive(Debug)]`
5450 |
5551LL + #[derive(Debug)]
tests/ui/impl-trait/precise-capturing/migration-note.stderr-1
......@@ -282,7 +282,6 @@ note: this call may capture more lifetimes than intended, because Rust 2024 has
282282 |
283283LL | let x = { let x = display_len(&mut vec![0]); x };
284284 | ^^^^^^^^^^^^^^^^^^^^^^^^^
285 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
286285help: use the precise capturing `use<...>` syntax to make the captures explicit
287286 |
288287LL | fn display_len<T>(x: &Vec<T>) -> impl Display + use<T> {
tests/ui/inference/need_type_info/issue-107745-avoid-expr-from-macro-expansion.stderr-2
......@@ -3,8 +3,6 @@ error[E0282]: type annotations needed
33 |
44LL | println!("{:?}", []);
55 | ^^ cannot infer type
6 |
7 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
86
97error: aborting due to 1 previous error
108
tests/ui/issues/issue-42796.stderr-1
......@@ -9,7 +9,6 @@ LL | let mut s_copy = s;
99LL | println!("{}", s);
1010 | ^ value borrowed here after move
1111 |
12 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1312help: consider cloning the value if the performance cost is acceptable
1413 |
1514LL | let mut s_copy = s.clone();
tests/ui/iterators/iter-macro-not-async-closure.stderr-2
......@@ -35,7 +35,6 @@ note: required by a bound in `call_async_once`
3535 |
3636LL | async fn call_async_once(f: impl AsyncFnOnce()) {
3737 | ^^^^^^^^^^^^^ required by this bound in `call_async_once`
38 = note: this error originates in the macro `pin` (in Nightly builds, run with -Z macro-backtrace for more info)
3938
4039error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}: AsyncFnOnce()` is not satisfied
4140 --> $DIR/iter-macro-not-async-closure.rs:25:13
......@@ -48,7 +47,6 @@ note: required by a bound in `call_async_once`
4847 |
4948LL | async fn call_async_once(f: impl AsyncFnOnce()) {
5049 | ^^^^^^^^^^^^^ required by this bound in `call_async_once`
51 = note: this error originates in the macro `pin` (in Nightly builds, run with -Z macro-backtrace for more info)
5250
5351error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}: AsyncFnOnce()` is not satisfied
5452 --> $DIR/iter-macro-not-async-closure.rs:30:5
tests/ui/lifetimes/borrowck-let-suggestion.stderr-1
......@@ -9,7 +9,6 @@ LL |
99LL | x.use_mut();
1010 | - borrow later used here
1111 |
12 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
1312help: consider consuming the `Vec<i32>` when turning it into an `Iterator`
1413 |
1514LL | let mut x = vec![1].into_iter();
tests/ui/lint/dead-code/closure-bang.stderr-1
......@@ -11,7 +11,6 @@ note: the lint level is defined here
1111 |
1212LL | #![deny(unreachable_code)]
1313 | ^^^^^^^^^^^^^^^^
14 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615error: aborting due to 1 previous error
1716
tests/ui/lint/fn-ptr-comparisons-some.stderr-1
......@@ -18,7 +18,6 @@ LL | assert_eq!(Some::<FnPtr>(func), Some(func as unsafe extern "C" fn()));
1818 = note: the address of the same function can vary between different codegen units
1919 = note: furthermore, different functions could have the same address after being merged together
2020 = note: for more information visit <https://doc.rust-lang.org/nightly/core/ptr/fn.fn_addr_eq.html>
21 = note: this warning originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
2221
2322warning: 2 warnings emitted
2423
tests/ui/lint/fn-ptr-comparisons-weird.stderr-2
......@@ -61,7 +61,6 @@ LL | let _ = assert_eq!(g, g);
6161 = note: the address of the same function can vary between different codegen units
6262 = note: furthermore, different functions could have the same address after being merged together
6363 = note: for more information visit <https://doc.rust-lang.org/nightly/core/ptr/fn.fn_addr_eq.html>
64 = note: this warning originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
6564
6665warning: function pointer comparisons do not produce meaningful results since their addresses are not guaranteed to be unique
6766 --> $DIR/fn-ptr-comparisons-weird.rs:35:13
......@@ -72,7 +71,6 @@ LL | let _ = assert_ne!(g, g);
7271 = note: the address of the same function can vary between different codegen units
7372 = note: furthermore, different functions could have the same address after being merged together
7473 = note: for more information visit <https://doc.rust-lang.org/nightly/core/ptr/fn.fn_addr_eq.html>
75 = note: this warning originates in the macro `assert_ne` (in Nightly builds, run with -Z macro-backtrace for more info)
7674
7775warning: 7 warnings emitted
7876
tests/ui/lint/lint-type-overflow2.rs+6
......@@ -1,13 +1,19 @@
11//@ compile-flags: -O
22
3#![feature(f16)]
4#![feature(f128)]
35#![deny(overflowing_literals)]
46
57fn main() {
68 let x2: i8 = --128; //~ ERROR literal out of range for `i8`
79 //~| WARN use of a double negation
810
11 let x = -65520.0_f16; //~ ERROR literal out of range for `f16`
12 let x = 65520.0_f16; //~ ERROR literal out of range for `f16`
913 let x = -3.40282357e+38_f32; //~ ERROR literal out of range for `f32`
1014 let x = 3.40282357e+38_f32; //~ ERROR literal out of range for `f32`
1115 let x = -1.7976931348623159e+308_f64; //~ ERROR literal out of range for `f64`
1216 let x = 1.7976931348623159e+308_f64; //~ ERROR literal out of range for `f64`
17 let x = -1.1897314953572317650857593266280075e+4932_f128; //~ ERROR literal out of range for `f128`
18 let x = 1.1897314953572317650857593266280075e+4932_f128; //~ ERROR literal out of range for `f128`
1319}
tests/ui/lint/lint-type-overflow2.stderr+40-8
......@@ -1,5 +1,5 @@
11warning: use of a double negation
2 --> $DIR/lint-type-overflow2.rs:6:18
2 --> $DIR/lint-type-overflow2.rs:8:18
33 |
44LL | let x2: i8 = --128;
55 | ^^^^^
......@@ -13,7 +13,7 @@ LL | let x2: i8 = -(-128);
1313 | + +
1414
1515error: literal out of range for `i8`
16 --> $DIR/lint-type-overflow2.rs:6:20
16 --> $DIR/lint-type-overflow2.rs:8:20
1717 |
1818LL | let x2: i8 = --128;
1919 | ^^^
......@@ -21,13 +21,29 @@ LL | let x2: i8 = --128;
2121 = note: the literal `128` does not fit into the type `i8` whose range is `-128..=127`
2222 = help: consider using the type `u8` instead
2323note: the lint level is defined here
24 --> $DIR/lint-type-overflow2.rs:3:9
24 --> $DIR/lint-type-overflow2.rs:5:9
2525 |
2626LL | #![deny(overflowing_literals)]
2727 | ^^^^^^^^^^^^^^^^^^^^
2828
29error: literal out of range for `f16`
30 --> $DIR/lint-type-overflow2.rs:11:14
31 |
32LL | let x = -65520.0_f16;
33 | ^^^^^^^^^^^
34 |
35 = note: the literal `65520.0_f16` does not fit into the type `f16` and will be converted to `f16::INFINITY`
36
37error: literal out of range for `f16`
38 --> $DIR/lint-type-overflow2.rs:12:14
39 |
40LL | let x = 65520.0_f16;
41 | ^^^^^^^^^^^
42 |
43 = note: the literal `65520.0_f16` does not fit into the type `f16` and will be converted to `f16::INFINITY`
44
2945error: literal out of range for `f32`
30 --> $DIR/lint-type-overflow2.rs:9:14
46 --> $DIR/lint-type-overflow2.rs:13:14
3147 |
3248LL | let x = -3.40282357e+38_f32;
3349 | ^^^^^^^^^^^^^^^^^^
......@@ -35,7 +51,7 @@ LL | let x = -3.40282357e+38_f32;
3551 = note: the literal `3.40282357e+38_f32` does not fit into the type `f32` and will be converted to `f32::INFINITY`
3652
3753error: literal out of range for `f32`
38 --> $DIR/lint-type-overflow2.rs:10:14
54 --> $DIR/lint-type-overflow2.rs:14:14
3955 |
4056LL | let x = 3.40282357e+38_f32;
4157 | ^^^^^^^^^^^^^^^^^^
......@@ -43,7 +59,7 @@ LL | let x = 3.40282357e+38_f32;
4359 = note: the literal `3.40282357e+38_f32` does not fit into the type `f32` and will be converted to `f32::INFINITY`
4460
4561error: literal out of range for `f64`
46 --> $DIR/lint-type-overflow2.rs:11:14
62 --> $DIR/lint-type-overflow2.rs:15:14
4763 |
4864LL | let x = -1.7976931348623159e+308_f64;
4965 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
......@@ -51,12 +67,28 @@ LL | let x = -1.7976931348623159e+308_f64;
5167 = note: the literal `1.7976931348623159e+308_f64` does not fit into the type `f64` and will be converted to `f64::INFINITY`
5268
5369error: literal out of range for `f64`
54 --> $DIR/lint-type-overflow2.rs:12:14
70 --> $DIR/lint-type-overflow2.rs:16:14
5571 |
5672LL | let x = 1.7976931348623159e+308_f64;
5773 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
5874 |
5975 = note: the literal `1.7976931348623159e+308_f64` does not fit into the type `f64` and will be converted to `f64::INFINITY`
6076
61error: aborting due to 5 previous errors; 1 warning emitted
77error: literal out of range for `f128`
78 --> $DIR/lint-type-overflow2.rs:17:14
79 |
80LL | let x = -1.1897314953572317650857593266280075e+4932_f128;
81 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
82 |
83 = note: the literal `1.1897314953572317650857593266280075e+4932_f128` does not fit into the type `f128` and will be converted to `f128::INFINITY`
84
85error: literal out of range for `f128`
86 --> $DIR/lint-type-overflow2.rs:18:14
87 |
88LL | let x = 1.1897314953572317650857593266280075e+4932_f128;
89 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
90 |
91 = note: the literal `1.1897314953572317650857593266280075e+4932_f128` does not fit into the type `f128` and will be converted to `f128::INFINITY`
92
93error: aborting due to 9 previous errors; 1 warning emitted
6294
tests/ui/liveness/liveness-move-in-while.stderr-1
......@@ -35,7 +35,6 @@ LL | while true { while true { while true { x = y; x.clone(); } } }
3535 | | inside of this loop
3636 | inside of this loop
3737 |
38 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
3938help: consider cloning the value if the performance cost is acceptable
4039 |
4140LL | while true { while true { while true { x = y.clone(); x.clone(); } } }
tests/ui/liveness/liveness-use-after-move.stderr-1
......@@ -9,7 +9,6 @@ LL |
99LL | println!("{}", *x);
1010 | ^^ value borrowed here after move
1111 |
12 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1312help: consider cloning the value if the performance cost is acceptable
1413 |
1514LL | let y = x.clone();
tests/ui/liveness/liveness-use-after-send.stderr-1
......@@ -13,7 +13,6 @@ note: consider changing this parameter type in function `send` to borrow instead
1313 |
1414LL | fn send<T:Send + std::fmt::Debug>(ch: Chan<T>, data: T) {
1515 | ---- in this function ^ this parameter takes ownership of the value
16 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1716help: consider cloning the value if the performance cost is acceptable
1817 |
1918LL | send(ch, message.clone());
tests/ui/loops/loop-proper-liveness.stderr-1
......@@ -7,7 +7,6 @@ LL | let x: i32;
77LL | println!("{:?}", x);
88 | ^ `x` used here but it isn't initialized
99 |
10 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1110help: consider assigning a value
1211 |
1312LL | let x: i32 = 42;
tests/ui/macros/assert.with-generic-asset.stderr-2
......@@ -15,8 +15,6 @@ error: macro requires a boolean expression as an argument
1515 |
1616LL | debug_assert!();
1717 | ^^^^^^^^^^^^^^^ boolean expression required
18 |
19 = note: this error originates in the macro `debug_assert` (in Nightly builds, run with -Z macro-backtrace for more info)
2018
2119error: expected expression, found keyword `struct`
2220 --> $DIR/assert.rs:8:19
tests/ui/macros/assert.without-generic-asset.stderr-2
......@@ -15,8 +15,6 @@ error: macro requires a boolean expression as an argument
1515 |
1616LL | debug_assert!();
1717 | ^^^^^^^^^^^^^^^ boolean expression required
18 |
19 = note: this error originates in the macro `debug_assert` (in Nightly builds, run with -Z macro-backtrace for more info)
2018
2119error: expected expression, found keyword `struct`
2220 --> $DIR/assert.rs:8:19
tests/ui/macros/failed-to-reparse-issue-139445.stderr-4
......@@ -9,16 +9,12 @@ error: expected `while`, `for`, `loop` or `{` after a label
99 |
1010LL | assert_eq!(3, 'a,)
1111 | ^^^^^^^^^^^^^^^^^^ expected `while`, `for`, `loop` or `{` after a label
12 |
13 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
1412
1513error: expected expression, found ``
1614 --> $DIR/failed-to-reparse-issue-139445.rs:2:5
1715 |
1816LL | assert_eq!(3, 'a,)
1917 | ^^^^^^^^^^^^^^^^^^ expected expression
20 |
21 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
2218
2319error: aborting due to 3 previous errors
2420
tests/ui/macros/format-parse-errors.stderr-2
......@@ -3,8 +3,6 @@ error: requires at least a format string argument
33 |
44LL | format!();
55 | ^^^^^^^^^
6 |
7 = note: this error originates in the macro `$crate::__export::format_args` which comes from the expansion of the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
86
97error: expected expression, found keyword `struct`
108 --> $DIR/format-parse-errors.rs:5:13
tests/ui/macros/macro-expansion-empty-span-147255.stderr-1
......@@ -8,7 +8,6 @@ LL | println!("{}", x_str);
88 |
99 = help: the trait `std::fmt::Display` is not implemented for `()`
1010 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
11 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1211
1312error: aborting due to 1 previous error
1413
tests/ui/macros/macro-local-data-key-priv.stderr-1
......@@ -9,7 +9,6 @@ note: the constant `baz` is defined here
99 |
1010LL | thread_local!(static baz: f64 = 0.0);
1111 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
12 = note: this error originates in the macro `$crate::thread::local_impl::thread_local_process_attrs` which comes from the expansion of the macro `thread_local` (in Nightly builds, run with -Z macro-backtrace for more info)
1312
1413error: aborting due to 1 previous error
1514
tests/ui/macros/vec-macro-in-pattern.stderr-3
......@@ -5,7 +5,6 @@ LL | Some(vec![43]) => {}
55 | ^^^^^^^^ not a tuple struct or tuple variant
66 |
77 = note: function calls are not allowed in patterns: <https://doc.rust-lang.org/book/ch19-00-patterns.html>
8 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
98
109error[E0658]: usage of qualified paths in this context is experimental
1110 --> $DIR/vec-macro-in-pattern.rs:7:14
......@@ -16,7 +15,6 @@ LL | Some(vec![43]) => {}
1615 = note: see issue #86935 <https://github.com/rust-lang/rust/issues/86935> for more information
1716 = help: add `#![feature(more_qualified_paths)]` to the crate attributes to enable
1817 = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
19 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
2018
2119error[E0164]: expected tuple struct or tuple variant, found associated function `<[_]>::into_vec`
2220 --> $DIR/vec-macro-in-pattern.rs:7:14
......@@ -25,7 +23,6 @@ LL | Some(vec![43]) => {}
2523 | ^^^^^^^^ `fn` calls are not allowed in patterns
2624 |
2725 = help: for more information, visit https://doc.rust-lang.org/book/ch19-00-patterns.html
28 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
2926
3027error: aborting due to 3 previous errors
3128
tests/ui/mismatched_types/mismatched-types-issue-126222.stderr-4
......@@ -4,7 +4,6 @@ error[E0308]: mismatched types
44LL | x => dbg!(x),
55 | ^^^^^^^ expected `()`, found integer
66 |
7 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
87help: you might have meant to return this value
98 |
109LL | x => return dbg!(x),
......@@ -16,7 +15,6 @@ error[E0308]: mismatched types
1615LL | dbg!(x)
1716 | ^^^^^^^ expected `()`, found integer
1817 |
19 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
2018help: you might have meant to return this value
2119 |
2220LL | return dbg!(x)
......@@ -28,7 +26,6 @@ error[E0308]: mismatched types
2826LL | _ => dbg!(1)
2927 | ^^^^^^^ expected `()`, found integer
3028 |
31 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
3229help: you might have meant to return this value
3330 |
3431LL | _ => return dbg!(1)
......@@ -40,7 +37,6 @@ error[E0308]: mismatched types
4037LL | _ => {dbg!(1)}
4138 | ^^^^^^^ expected `()`, found integer
4239 |
43 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
4440help: you might have meant to return this value
4541 |
4642LL | _ => {return dbg!(1)}
tests/ui/modules/issue-107649.stderr-1
......@@ -5,7 +5,6 @@ error[E0277]: `Dummy` doesn't implement `Debug`
55 | ^^^^^^^^^^^^^^^^ the trait `Debug` is not implemented for `Dummy`
66 |
77 = note: add `#[derive(Debug)]` to `Dummy` or manually `impl Debug for Dummy`
8 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
98help: consider annotating `Dummy` with `#[derive(Debug)]`
109 --> $DIR/auxiliary/dummy_lib.rs:2:1
1110 |
tests/ui/moves/moves-based-on-type-capture-clause-bad.stderr-1
......@@ -11,7 +11,6 @@ LL | });
1111LL | println!("{}", x);
1212 | ^ value borrowed here after move
1313 |
14 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1514help: consider cloning the value before moving it into the closure
1615 |
1716LL ~ let value = x.clone();
tests/ui/nll/polonius/nll-problem-case-3-issue-21906.nll.stderr-2
......@@ -59,8 +59,6 @@ LL | return Some(y);
5959...
6060LL | println!("{:?}", x.data);
6161 | ^^^^^^ immutable borrow occurs here
62 |
63 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
6462
6563error[E0499]: cannot borrow `*vec` as mutable more than once at a time
6664 --> $DIR/nll-problem-case-3-issue-21906.rs:77:9
tests/ui/on-unimplemented/no-debug.stderr-4
......@@ -8,7 +8,6 @@ LL | println!("{:?} {:?}", Foo, Bar);
88 |
99 = help: the trait `Debug` is not implemented for `Foo`
1010 = note: add `#[derive(Debug)]` to `Foo` or manually `impl Debug for Foo`
11 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1211help: consider annotating `Foo` with `#[derive(Debug)]`
1312 |
1413LL + #[derive(Debug)]
......@@ -24,7 +23,6 @@ LL | println!("{:?} {:?}", Foo, Bar);
2423 | required by this formatting parameter
2524 |
2625 = help: the trait `Debug` is not implemented for `Bar`
27 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2826
2927error[E0277]: `Foo` doesn't implement `std::fmt::Display`
3028 --> $DIR/no-debug.rs:11:23
......@@ -40,7 +38,6 @@ help: the trait `std::fmt::Display` is not implemented for `Foo`
4038LL | struct Foo;
4139 | ^^^^^^^^^^
4240 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
43 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
4441
4542error[E0277]: `Bar` doesn't implement `std::fmt::Display`
4643 --> $DIR/no-debug.rs:11:28
......@@ -52,7 +49,6 @@ LL | println!("{} {}", Foo, Bar);
5249 |
5350 = help: the trait `std::fmt::Display` is not implemented for `Bar`
5451 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
55 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
5652
5753error: aborting due to 4 previous errors
5854
tests/ui/pattern/deref-patterns/ice-adjust-mode-unimplemented-for-constblock.stderr-3
......@@ -5,7 +5,6 @@ LL | let vec![const { vec![] }]: Vec<usize> = vec![];
55 | ^^^^^^^^^^^^^^^^^^^^^^ not a tuple struct or tuple variant
66 |
77 = note: function calls are not allowed in patterns: <https://doc.rust-lang.org/book/ch19-00-patterns.html>
8 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
98
109error[E0658]: usage of qualified paths in this context is experimental
1110 --> $DIR/ice-adjust-mode-unimplemented-for-constblock.rs:5:9
......@@ -16,7 +15,6 @@ LL | let vec![const { vec![] }]: Vec<usize> = vec![];
1615 = note: see issue #86935 <https://github.com/rust-lang/rust/issues/86935> for more information
1716 = help: add `#![feature(more_qualified_paths)]` to the crate attributes to enable
1817 = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
19 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
2018
2119error: arbitrary expressions aren't allowed in patterns
2220 --> $DIR/ice-adjust-mode-unimplemented-for-constblock.rs:5:14
......@@ -33,7 +31,6 @@ LL | let vec![const { vec![] }]: Vec<usize> = vec![];
3331 | ^^^^^^^^^^^^^^^^^^^^^^ `fn` calls are not allowed in patterns
3432 |
3533 = help: for more information, visit https://doc.rust-lang.org/book/ch19-00-patterns.html
36 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
3734
3835error: aborting due to 4 previous errors
3936
tests/ui/pin-macro/lifetime_errors_on_promotion_misusage.stderr-2
......@@ -10,7 +10,6 @@ LL | stuff(phantom_pinned)
1010 | -------------- borrow later used here
1111 |
1212 = note: consider using a `let` binding to create a longer lived value
13 = note: this error originates in the macro `pin` (in Nightly builds, run with -Z macro-backtrace for more info)
1413
1514error[E0716]: temporary value dropped while borrowed
1615 --> $DIR/lifetime_errors_on_promotion_misusage.rs:18:30
......@@ -24,7 +23,6 @@ LL | };
2423 | - temporary value is freed at the end of this statement
2524 |
2625 = note: consider using a `let` binding to create a longer lived value
27 = note: this error originates in the macro `pin` (in Nightly builds, run with -Z macro-backtrace for more info)
2826
2927error: aborting due to 2 previous errors
3028
tests/ui/reachable/expr_again.stderr-1
......@@ -11,7 +11,6 @@ note: the lint level is defined here
1111 |
1212LL | #![deny(unreachable_code)]
1313 | ^^^^^^^^^^^^^^^^
14 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615error: aborting due to 1 previous error
1716
tests/ui/reachable/expr_block.stderr-2
......@@ -19,8 +19,6 @@ LL | return;
1919 | ------ any code following this expression is unreachable
2020LL | println!("foo");
2121 | ^^^^^^^^^^^^^^^ unreachable statement
22 |
23 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2422
2523error: aborting due to 2 previous errors
2624
tests/ui/reachable/expr_if.stderr-2
......@@ -23,8 +23,6 @@ LL | return;
2323...
2424LL | println!("But I am.");
2525 | ^^^^^^^^^^^^^^^^^^^^^ unreachable statement
26 |
27 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2826
2927error: aborting due to 2 previous errors
3028
tests/ui/reachable/expr_loop.stderr-5
......@@ -11,7 +11,6 @@ note: the lint level is defined here
1111 |
1212LL | #![deny(unreachable_code)]
1313 | ^^^^^^^^^^^^^^^^
14 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615error: unreachable statement
1716 --> $DIR/expr_loop.rs:21:5
......@@ -20,8 +19,6 @@ LL | loop { return; }
2019 | ------ any code following this expression is unreachable
2120LL | println!("I am dead.");
2221 | ^^^^^^^^^^^^^^^^^^^^^^ unreachable statement
23 |
24 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2522
2623error: unreachable statement
2724 --> $DIR/expr_loop.rs:32:5
......@@ -30,8 +27,6 @@ LL | loop { 'middle: loop { loop { break 'middle; } } }
3027 | -------------------------------------------------- any code following this expression is unreachable
3128LL | println!("I am dead.");
3229 | ^^^^^^^^^^^^^^^^^^^^^^ unreachable statement
33 |
34 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
3530
3631error: aborting due to 3 previous errors
3732
tests/ui/reachable/expr_match.stderr-5
......@@ -11,7 +11,6 @@ note: the lint level is defined here
1111 |
1212LL | #![deny(unreachable_code)]
1313 | ^^^^^^^^^^^^^^^^
14 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615error: unreachable statement
1716 --> $DIR/expr_match.rs:19:5
......@@ -20,8 +19,6 @@ LL | match () { () if false => return, () => return }
2019 | ------------------------------------------------ any code following this `match` expression is unreachable, as all arms diverge
2120LL | println!("I am dead");
2221 | ^^^^^^^^^^^^^^^^^^^^^ unreachable statement
23 |
24 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2522
2623error: unreachable expression
2724 --> $DIR/expr_match.rs:25:25
......@@ -42,8 +39,6 @@ LL | | }
4239 | |_____- any code following this `match` expression is unreachable, as all arms diverge
4340LL | println!("I am dead");
4441 | ^^^^^^^^^^^^^^^^^^^^^ unreachable statement
45 |
46 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
4742
4843error: aborting due to 4 previous errors
4944
tests/ui/reachable/unreachable-code-ret.stderr-1
......@@ -11,7 +11,6 @@ note: the lint level is defined here
1111 |
1212LL | #![deny(unreachable_code)]
1313 | ^^^^^^^^^^^^^^^^
14 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615error: aborting due to 1 previous error
1716
tests/ui/resolve/underscore-bindings-disambiguators.stderr-12
......@@ -21,48 +21,36 @@ error[E0080]: evaluation panicked: not yet implemented
2121 |
2222LL | const _: () = todo!();
2323 | ^^^^^^^ evaluation of `impls::_` failed here
24 |
25 = note: this error originates in the macro `todo` (in Nightly builds, run with -Z macro-backtrace for more info)
2624
2725error[E0080]: evaluation panicked: not yet implemented
2826 --> $DIR/underscore-bindings-disambiguators.rs:20:19
2927 |
3028LL | const _: () = todo!();
3129 | ^^^^^^^ evaluation of `impls::_` failed here
32 |
33 = note: this error originates in the macro `todo` (in Nightly builds, run with -Z macro-backtrace for more info)
3430
3531error[E0080]: evaluation panicked: not yet implemented
3632 --> $DIR/underscore-bindings-disambiguators.rs:21:19
3733 |
3834LL | const _: () = todo!();
3935 | ^^^^^^^ evaluation of `impls::_` failed here
40 |
41 = note: this error originates in the macro `todo` (in Nightly builds, run with -Z macro-backtrace for more info)
4236
4337error[E0080]: evaluation panicked: not yet implemented
4438 --> $DIR/underscore-bindings-disambiguators.rs:22:19
4539 |
4640LL | const _: () = todo!();
4741 | ^^^^^^^ evaluation of `impls::_` failed here
48 |
49 = note: this error originates in the macro `todo` (in Nightly builds, run with -Z macro-backtrace for more info)
5042
5143error[E0080]: evaluation panicked: not yet implemented
5244 --> $DIR/underscore-bindings-disambiguators.rs:23:19
5345 |
5446LL | const _: () = todo!();
5547 | ^^^^^^^ evaluation of `impls::_` failed here
56 |
57 = note: this error originates in the macro `todo` (in Nightly builds, run with -Z macro-backtrace for more info)
5848
5949error[E0080]: evaluation panicked: not yet implemented
6050 --> $DIR/underscore-bindings-disambiguators.rs:28:15
6151 |
6252LL | const _: () = todo!();
6353 | ^^^^^^^ evaluation of `_` failed here
64 |
65 = note: this error originates in the macro `todo` (in Nightly builds, run with -Z macro-backtrace for more info)
6654
6755error: aborting due to 8 previous errors
6856
tests/ui/rfcs/rfc-0000-never_patterns/diverge-causes-unreachable-code.stderr-7
......@@ -11,7 +11,6 @@ note: the lint level is defined here
1111 |
1212LL | #![deny(unreachable_code)]
1313 | ^^^^^^^^^^^^^^^^
14 = note: this error originates in the macro `$crate::print` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615error: unreachable statement
1716 --> $DIR/diverge-causes-unreachable-code.rs:16:5
......@@ -20,8 +19,6 @@ LL | fn ref_never_arg(&!: &Void) -> u32 {
2019 | -- any code following a never pattern is unreachable
2120LL | println!();
2221 | ^^^^^^^^^^ unreachable statement
23 |
24 = note: this error originates in the macro `$crate::print` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2522
2623error: unreachable statement
2724 --> $DIR/diverge-causes-unreachable-code.rs:25:5
......@@ -31,8 +28,6 @@ LL | let ! = *ptr;
3128LL | }
3229LL | println!();
3330 | ^^^^^^^^^^ unreachable statement
34 |
35 = note: this error originates in the macro `$crate::print` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
3631
3732error: unreachable statement
3833 --> $DIR/diverge-causes-unreachable-code.rs:34:5
......@@ -42,8 +37,6 @@ LL | match *ptr { ! };
4237LL | }
4338LL | println!();
4439 | ^^^^^^^^^^ unreachable statement
45 |
46 = note: this error originates in the macro `$crate::print` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
4740
4841error: aborting due to 4 previous errors
4942
tests/ui/rfcs/rfc-2361-dbg-macro/dbg-macro-move-semantics.stderr-1
......@@ -8,7 +8,6 @@ LL | let _ = dbg!(a);
88LL | let _ = dbg!(a);
99 | ^^^^^^^ value used here after move
1010 |
11 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
1211help: consider borrowing instead of transferring ownership
1312 |
1413LL | let _ = dbg!(&a);
tests/ui/rfcs/rfc-2361-dbg-macro/dbg-macro-requires-debug.stderr-1
......@@ -5,7 +5,6 @@ LL | let _: NotDebug = dbg!(NotDebug);
55 | ^^^^^^^^^^^^^^ the trait `Debug` is not implemented for `NotDebug`
66 |
77 = note: add `#[derive(Debug)]` to `NotDebug` or manually `impl Debug for NotDebug`
8 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
98help: consider annotating `NotDebug` with `#[derive(Debug)]`
109 |
1110LL + #[derive(Debug)]
tests/ui/span/coerce-suggestions.stderr-2
......@@ -56,8 +56,6 @@ error[E0308]: mismatched types
5656 |
5757LL | s = format!("foo");
5858 | ^^^^^^^^^^^^^^ expected `&mut String`, found `String`
59 |
60 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
6159
6260error: aborting due to 5 previous errors
6361
tests/ui/span/issue-33884.stderr-2
......@@ -3,8 +3,6 @@ error[E0308]: mismatched types
33 |
44LL | stream.write_fmt(format!("message received"))
55 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `Arguments<'_>`, found `String`
6 |
7 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
86
97error: aborting due to 1 previous error
108
tests/ui/span/issue-39698.stderr-2
......@@ -71,8 +71,6 @@ LL | T::T1(a, d) | T::T2(d, b) | T::T3(c) | T::T4(a) => { println!("{:?}
7171 | | binding initialized here in some conditions
7272 | binding initialized here in some conditions
7373 | binding declared here but left uninitialized
74 |
75 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
7674
7775error: aborting due to 5 previous errors
7876
tests/ui/span/slice-borrow.stderr-1
......@@ -10,7 +10,6 @@ LL | y.use_ref();
1010 | - borrow later used here
1111 |
1212 = note: consider using a `let` binding to create a longer lived value
13 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
1413
1514error: aborting due to 1 previous error
1615
tests/ui/statics/check-values-constraints.stderr-21
......@@ -16,8 +16,6 @@ error[E0010]: allocations are not allowed in statics
1616 |
1717LL | static STATIC11: Vec<MyOwned> = vec![MyOwned];
1818 | ^^^^^^^^^^^^^ allocation not allowed in statics
19 |
20 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
2119
2220error[E0015]: cannot call non-const method `slice::<impl [MyOwned]>::into_vec::<std::alloc::Global>` in statics
2321 --> $DIR/check-values-constraints.rs:81:33
......@@ -27,7 +25,6 @@ LL | static STATIC11: Vec<MyOwned> = vec![MyOwned];
2725 |
2826 = note: calls in statics are limited to constant functions, tuple structs and tuple variants
2927 = note: consider wrapping this expression in `std::sync::LazyLock::new(|| ...)`
30 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
3128
3229error[E0015]: cannot call non-const method `<str as ToString>::to_string` in statics
3330 --> $DIR/check-values-constraints.rs:92:38
......@@ -50,8 +47,6 @@ error[E0010]: allocations are not allowed in statics
5047 |
5148LL | vec![MyOwned],
5249 | ^^^^^^^^^^^^^ allocation not allowed in statics
53 |
54 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
5550
5651error[E0015]: cannot call non-const method `slice::<impl [MyOwned]>::into_vec::<std::alloc::Global>` in statics
5752 --> $DIR/check-values-constraints.rs:96:5
......@@ -61,15 +56,12 @@ LL | vec![MyOwned],
6156 |
6257 = note: calls in statics are limited to constant functions, tuple structs and tuple variants
6358 = note: consider wrapping this expression in `std::sync::LazyLock::new(|| ...)`
64 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
6559
6660error[E0010]: allocations are not allowed in statics
6761 --> $DIR/check-values-constraints.rs:98:5
6862 |
6963LL | vec![MyOwned],
7064 | ^^^^^^^^^^^^^ allocation not allowed in statics
71 |
72 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
7365
7466error[E0015]: cannot call non-const method `slice::<impl [MyOwned]>::into_vec::<std::alloc::Global>` in statics
7567 --> $DIR/check-values-constraints.rs:98:5
......@@ -79,15 +71,12 @@ LL | vec![MyOwned],
7971 |
8072 = note: calls in statics are limited to constant functions, tuple structs and tuple variants
8173 = note: consider wrapping this expression in `std::sync::LazyLock::new(|| ...)`
82 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
8374
8475error[E0010]: allocations are not allowed in statics
8576 --> $DIR/check-values-constraints.rs:103:6
8677 |
8778LL | &vec![MyOwned],
8879 | ^^^^^^^^^^^^^ allocation not allowed in statics
89 |
90 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
9180
9281error[E0015]: cannot call non-const method `slice::<impl [MyOwned]>::into_vec::<std::alloc::Global>` in statics
9382 --> $DIR/check-values-constraints.rs:103:6
......@@ -97,15 +86,12 @@ LL | &vec![MyOwned],
9786 |
9887 = note: calls in statics are limited to constant functions, tuple structs and tuple variants
9988 = note: consider wrapping this expression in `std::sync::LazyLock::new(|| ...)`
100 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
10189
10290error[E0010]: allocations are not allowed in statics
10391 --> $DIR/check-values-constraints.rs:105:6
10492 |
10593LL | &vec![MyOwned],
10694 | ^^^^^^^^^^^^^ allocation not allowed in statics
107 |
108 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
10995
11096error[E0015]: cannot call non-const method `slice::<impl [MyOwned]>::into_vec::<std::alloc::Global>` in statics
11197 --> $DIR/check-values-constraints.rs:105:6
......@@ -115,15 +101,12 @@ LL | &vec![MyOwned],
115101 |
116102 = note: calls in statics are limited to constant functions, tuple structs and tuple variants
117103 = note: consider wrapping this expression in `std::sync::LazyLock::new(|| ...)`
118 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
119104
120105error[E0010]: allocations are not allowed in statics
121106 --> $DIR/check-values-constraints.rs:111:31
122107 |
123108LL | static STATIC19: Vec<isize> = vec![3];
124109 | ^^^^^^^ allocation not allowed in statics
125 |
126 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
127110
128111error[E0015]: cannot call non-const method `slice::<impl [isize]>::into_vec::<std::alloc::Global>` in statics
129112 --> $DIR/check-values-constraints.rs:111:31
......@@ -133,15 +116,12 @@ LL | static STATIC19: Vec<isize> = vec![3];
133116 |
134117 = note: calls in statics are limited to constant functions, tuple structs and tuple variants
135118 = note: consider wrapping this expression in `std::sync::LazyLock::new(|| ...)`
136 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
137119
138120error[E0010]: allocations are not allowed in statics
139121 --> $DIR/check-values-constraints.rs:117:32
140122 |
141123LL | static x: Vec<isize> = vec![3];
142124 | ^^^^^^^ allocation not allowed in statics
143 |
144 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
145125
146126error[E0015]: cannot call non-const method `slice::<impl [isize]>::into_vec::<std::alloc::Global>` in statics
147127 --> $DIR/check-values-constraints.rs:117:32
......@@ -151,7 +131,6 @@ LL | static x: Vec<isize> = vec![3];
151131 |
152132 = note: calls in statics are limited to constant functions, tuple structs and tuple variants
153133 = note: consider wrapping this expression in `std::sync::LazyLock::new(|| ...)`
154 = note: this error originates in the macro `vec` (in Nightly builds, run with -Z macro-backtrace for more info)
155134
156135error[E0507]: cannot move out of static item `x`
157136 --> $DIR/check-values-constraints.rs:119:9
tests/ui/suggestions/bound-suggestions.stderr-6
......@@ -6,7 +6,6 @@ LL | println!("{:?}", t);
66 | |
77 | required by this formatting parameter
88 |
9 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
109help: consider restricting opaque type `impl Sized` with trait `Debug`
1110 |
1211LL | fn test_impl(t: impl Sized + std::fmt::Debug) {
......@@ -20,7 +19,6 @@ LL | println!("{:?}", t);
2019 | |
2120 | required by this formatting parameter
2221 |
23 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2422help: consider restricting type parameter `T` with trait `Debug`
2523 |
2624LL | fn test_no_bounds<T: std::fmt::Debug>(t: T) {
......@@ -34,7 +32,6 @@ LL | println!("{:?}", t);
3432 | |
3533 | required by this formatting parameter
3634 |
37 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
3835help: consider further restricting type parameter `T` with trait `Debug`
3936 |
4037LL | fn test_one_bound<T: Sized + std::fmt::Debug>(t: T) {
......@@ -48,7 +45,6 @@ LL | println!("{:?} {:?}", x, y);
4845 | |
4946 | required by this formatting parameter
5047 |
51 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
5248help: consider further restricting type parameter `Y` with trait `Debug`
5349 |
5450LL | fn test_no_bounds_where<X, Y>(x: X, y: Y) where X: std::fmt::Debug, Y: std::fmt::Debug {
......@@ -62,7 +58,6 @@ LL | println!("{:?}", x);
6258 | |
6359 | required by this formatting parameter
6460 |
65 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
6661help: consider further restricting type parameter `X` with trait `Debug`
6762 |
6863LL | fn test_one_bound_where<X>(x: X) where X: Sized + std::fmt::Debug {
......@@ -76,7 +71,6 @@ LL | println!("{:?}", x);
7671 | |
7772 | required by this formatting parameter
7873 |
79 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
8074help: consider further restricting type parameter `X` with trait `Debug`
8175 |
8276LL | fn test_many_bounds_where<X>(x: X) where X: Sized + std::fmt::Debug, X: Sized {
tests/ui/suggestions/issue-97760.stderr-1
......@@ -6,7 +6,6 @@ LL | println!("{x}");
66 |
77 = help: the trait `std::fmt::Display` is not implemented for `<impl IntoIterator as IntoIterator>::Item`
88 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
9 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
109help: introduce a type parameter with a trait bound instead of using `impl Trait`
1110 |
1211LL ~ pub fn print_values<I: IntoIterator>(values: &I)
tests/ui/suggestions/path-display.stderr-2
......@@ -10,7 +10,6 @@ LL | println!("{}", path);
1010 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
1111 = note: call `.display()` or `.to_string_lossy()` to safely print paths, as they may contain non-Unicode data
1212 = note: required for `&Path` to implement `std::fmt::Display`
13 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1413
1514error[E0277]: `PathBuf` doesn't implement `std::fmt::Display`
1615 --> $DIR/path-display.rs:9:20
......@@ -23,7 +22,6 @@ LL | println!("{}", path);
2322 = help: the trait `std::fmt::Display` is not implemented for `PathBuf`
2423 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
2524 = note: call `.display()` or `.to_string_lossy()` to safely print paths, as they may contain non-Unicode data
26 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2725
2826error: aborting due to 2 previous errors
2927
tests/ui/thread-local/no-unstable.stderr-4
......@@ -10,7 +10,6 @@ LL | | }
1010 = help: add `#![feature(rustc_attrs)]` to the crate attributes to enable
1111 = note: the `#[rustc_dummy]` attribute is an internal implementation detail that will never be stable
1212 = note: the `#[rustc_dummy]` attribute is used for rustc unit tests
13 = note: this error originates in the macro `$crate::thread::local_impl::thread_local_process_attrs` which comes from the expansion of the macro `thread_local` (in Nightly builds, run with -Z macro-backtrace for more info)
1413
1514error[E0658]: use of an internal attribute
1615 --> $DIR/no-unstable.rs:1:1
......@@ -24,7 +23,6 @@ LL | | }
2423 = help: add `#![feature(rustc_attrs)]` to the crate attributes to enable
2524 = note: the `#[rustc_dummy]` attribute is an internal implementation detail that will never be stable
2625 = note: the `#[rustc_dummy]` attribute is used for rustc unit tests
27 = note: this error originates in the macro `$crate::thread::local_impl::thread_local_process_attrs` which comes from the expansion of the macro `thread_local` (in Nightly builds, run with -Z macro-backtrace for more info)
2826
2927error[E0658]: `#[used(linker)]` is currently unstable
3028 --> $DIR/no-unstable.rs:1:1
......@@ -38,7 +36,6 @@ LL | | }
3836 = note: see issue #93798 <https://github.com/rust-lang/rust/issues/93798> for more information
3937 = help: add `#![feature(used_with_arg)]` to the crate attributes to enable
4038 = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
41 = note: this error originates in the macro `$crate::thread::local_impl::thread_local_process_attrs` which comes from the expansion of the macro `thread_local` (in Nightly builds, run with -Z macro-backtrace for more info)
4239
4340error: `#[used]` attribute cannot be used on constants
4441 --> $DIR/no-unstable.rs:1:1
......@@ -50,7 +47,6 @@ LL | | }
5047 | |_^
5148 |
5249 = help: `#[used]` can only be applied to statics
53 = note: this error originates in the macro `$crate::thread::local_impl::thread_local_process_attrs` which comes from the expansion of the macro `thread_local` (in Nightly builds, run with -Z macro-backtrace for more info)
5450
5551error: aborting due to 4 previous errors
5652
tests/ui/traits/const-traits/issue-79450.stderr-1
......@@ -7,7 +7,6 @@ LL | println!("lul");
77note: function `_print` is not const
88 --> $SRC_DIR/std/src/io/stdio.rs:LL:COL
99 = note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
10 = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1110
1211error: aborting due to 1 previous error
1312
tests/ui/try-block/try-block-maybe-bad-lifetime.stderr-1
......@@ -22,7 +22,6 @@ LL | };
2222LL | println!("{}", x);
2323 | ^ value borrowed here after move
2424 |
25 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2625help: consider cloning the value if the performance cost is acceptable
2726 |
2827LL | ::std::mem::drop(x.clone());
tests/ui/try-block/try-block-opt-init.stderr-2
......@@ -9,8 +9,6 @@ LL | cfg_res = 5;
99...
1010LL | assert_eq!(cfg_res, 5);
1111 | ^^^^^^^^^^^^^^^^^^^^^^ `cfg_res` used here but it is possibly-uninitialized
12 |
13 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
1412
1513error: aborting due to 1 previous error
1614
tests/ui/type-alias-impl-trait/imply_bounds_from_bounds_param.edition2024.stderr-3
......@@ -35,7 +35,6 @@ note: this call may capture more lifetimes than intended, because Rust 2024 has
3535 |
3636LL | let mut thing = test(&mut z);
3737 | ^^^^^^^^^^^^
38 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
3938help: use the precise capturing `use<...>` syntax to make the captures explicit
4039 |
4140LL | fn test<'a>(y: &'a mut i32) -> impl PlusOne + use<> {
......@@ -57,7 +56,6 @@ note: this call may capture more lifetimes than intended, because Rust 2024 has
5756 |
5857LL | let mut thing = test(&mut z);
5958 | ^^^^^^^^^^^^
60 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
6159help: use the precise capturing `use<...>` syntax to make the captures explicit
6260 |
6361LL | fn test<'a>(y: &'a mut i32) -> impl PlusOne + use<> {
......@@ -79,7 +77,6 @@ note: this call may capture more lifetimes than intended, because Rust 2024 has
7977 |
8078LL | let mut thing = test(&mut z);
8179 | ^^^^^^^^^^^^
82 = note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
8380help: use the precise capturing `use<...>` syntax to make the captures explicit
8481 |
8582LL | fn test<'a>(y: &'a mut i32) -> impl PlusOne + use<> {
tests/ui/type-alias-impl-trait/nested.stderr-1
......@@ -20,7 +20,6 @@ LL | println!("{:?}", bar());
2020 | required by this formatting parameter
2121 |
2222 = help: the trait `Debug` is not implemented for `Bar`
23 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2423
2524error: aborting due to 2 previous errors
2625
tests/ui/type/binding-assigned-block-without-tail-expression.stderr-4
......@@ -11,7 +11,6 @@ LL | println!("{}", x);
1111 |
1212 = help: the trait `std::fmt::Display` is not implemented for `()`
1313 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
14 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1514
1615error[E0277]: `()` doesn't implement `std::fmt::Display`
1716 --> $DIR/binding-assigned-block-without-tail-expression.rs:15:20
......@@ -26,7 +25,6 @@ LL | println!("{}", y);
2625 |
2726 = help: the trait `std::fmt::Display` is not implemented for `()`
2827 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
29 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
3028
3129error[E0277]: `()` doesn't implement `std::fmt::Display`
3230 --> $DIR/binding-assigned-block-without-tail-expression.rs:16:20
......@@ -41,7 +39,6 @@ LL | println!("{}", z);
4139 |
4240 = help: the trait `std::fmt::Display` is not implemented for `()`
4341 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
44 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
4542
4643error[E0277]: `()` doesn't implement `std::fmt::Display`
4744 --> $DIR/binding-assigned-block-without-tail-expression.rs:17:20
......@@ -59,7 +56,6 @@ LL | println!("{}", s);
5956 |
6057 = help: the trait `std::fmt::Display` is not implemented for `()`
6158 = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
62 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
6359
6460error[E0308]: mismatched types
6561 --> $DIR/binding-assigned-block-without-tail-expression.rs:18:18
tests/ui/typeck/closure-ty-mismatch-issue-128561.stderr-2
......@@ -14,8 +14,6 @@ error[E0308]: mismatched types
1414 |
1515LL | b"abc".iter().for_each(|x| dbg!(x));
1616 | ^^^^^^^ expected `()`, found `&u8`
17 |
18 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
1917
2018error[E0308]: mismatched types
2119 --> $DIR/closure-ty-mismatch-issue-128561.rs:8:9
tests/ui/typeck/issue-110017-format-into-help-deletes-macro.stderr-1
......@@ -6,7 +6,6 @@ LL | Err(format!("error: {x}"))
66 |
77 = note: expected struct `Box<dyn std::error::Error>`
88 found struct `String`
9 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
109help: call `Into::into` on this expression to convert `String` into `Box<dyn std::error::Error>`
1110 |
1211LL | Err(format!("error: {x}").into())
tests/ui/typeck/issue-112007-leaked-writeln-macro-internals.stderr-1
......@@ -12,7 +12,6 @@ LL | | }
1212 |
1313 = note: expected unit type `()`
1414 found enum `Result<(), std::fmt::Error>`
15 = note: this error originates in the macro `writeln` (in Nightly builds, run with -Z macro-backtrace for more info)
1615help: consider using a semicolon here
1716 |
1817LL | };
tests/ui/typeck/question-mark-operator-suggestion-span.stderr-1
......@@ -12,7 +12,6 @@ LL | | }
1212 |
1313 = note: expected unit type `()`
1414 found enum `Result<(), std::fmt::Error>`
15 = note: this error originates in the macro `writeln` (in Nightly builds, run with -Z macro-backtrace for more info)
1615help: consider using a semicolon here
1716 |
1817LL | };
tests/ui/typeck/suggestions/suggest-clone-in-macro-issue-139253.stderr-2
......@@ -26,7 +26,6 @@ error[E0308]: mismatched types
2626LL | let c: S = dbg!(field);
2727 | ^^^^^^^^^^^ expected `S`, found `&S`
2828 |
29 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
3029help: consider using clone here
3130 |
3231LL | let c: S = dbg!(field).clone();
......@@ -38,7 +37,6 @@ error[E0308]: mismatched types
3837LL | let c: S = dbg!(dbg!(field));
3938 | ^^^^^^^^^^^^^^^^^ expected `S`, found `&S`
4039 |
41 = note: this error originates in the macro `$crate::macros::dbg_internal` which comes from the expansion of the macro `dbg` (in Nightly builds, run with -Z macro-backtrace for more info)
4240help: consider using clone here
4341 |
4442LL | let c: S = dbg!(dbg!(field)).clone();
tests/ui/uninhabited/void-branch.stderr-2
......@@ -16,7 +16,6 @@ note: the lint level is defined here
1616 |
1717LL | #![deny(unreachable_code)]
1818 | ^^^^^^^^^^^^^^^^
19 = note: this error originates in the macro `$crate::format_args` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
2019
2120error: unreachable expression
2221 --> $DIR/void-branch.rs:25:9
......@@ -31,7 +30,6 @@ note: this expression has type `Infallible`, which is uninhabited
3130 |
3231LL | infallible();
3332 | ^^^^^^^^^^^^
34 = note: this error originates in the macro `$crate::format_args` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
3533
3634error: aborting due to 2 previous errors
3735
tests/ui/use/use-after-move-based-on-type.stderr-1
......@@ -8,7 +8,6 @@ LL | let _y = x;
88LL | println!("{}", x);
99 | ^ value borrowed here after move
1010 |
11 = note: this error originates in the macro `$crate::format_args_nl` which comes from the expansion of the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
1211help: consider cloning the value if the performance cost is acceptable
1312 |
1413LL | let _y = x.clone();