From 20431706a863f92cb37dc512fef6e48d192aaf2c Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:11:38 +0200 Subject: Merging upstream version 1.66.0+dfsg1. Signed-off-by: Daniel Baumann --- vendor/syn/benches/rust.rs | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'vendor/syn/benches/rust.rs') diff --git a/vendor/syn/benches/rust.rs b/vendor/syn/benches/rust.rs index 5e4fba182..e3f8f550a 100644 --- a/vendor/syn/benches/rust.rs +++ b/vendor/syn/benches/rust.rs @@ -1,7 +1,7 @@ -// $ cargo bench --features full --bench rust +// $ cargo bench --features full,test --bench rust // // Syn only, useful for profiling: -// $ RUSTFLAGS='--cfg syn_only' cargo build --release --features full --bench rust +// $ RUSTFLAGS='--cfg syn_only' cargo build --release --features full,test --bench rust #![cfg_attr(not(syn_only), feature(rustc_private))] #![recursion_limit = "1024"] @@ -46,7 +46,7 @@ mod librustc_parse { use rustc_data_structures::sync::Lrc; use rustc_error_messages::FluentBundle; - use rustc_errors::{emitter::Emitter, Diagnostic, Handler}; + use rustc_errors::{emitter::Emitter, translation::Translate, Diagnostic, Handler}; use rustc_session::parse::ParseSess; use rustc_span::source_map::{FilePathMapping, SourceMap}; use rustc_span::{edition::Edition, FileName}; @@ -59,6 +59,9 @@ mod librustc_parse { fn source_map(&self) -> Option<&Lrc> { None } + } + + impl Translate for SilentEmitter { fn fluent_bundle(&self) -> Option<&Lrc> { None } @@ -88,7 +91,7 @@ mod librustc_parse { #[cfg(not(syn_only))] mod read_from_disk { pub fn bench(content: &str) -> Result<(), ()> { - let _ = content; + _ = content; Ok(()) } } -- cgit v1.2.3