thiserror/tests/ui/raw-identifier.rs
2024-11-04 15:22:04 -05:00

12 lines
193 B
Rust

use thiserror::Error;
#[derive(Error, Debug)]
#[error("error: {r#fn}")]
pub struct Error {
r#fn: &'static str,
}
fn main() {
let r#fn = "...";
let _ = format!("error: {r#fn}");
}