diff options
| author | Ralf Jung <post@ralfj.de> | 2024-05-22 10:08:32 +0200 |
|---|---|---|
| committer | Ralf Jung <post@ralfj.de> | 2024-05-22 10:08:32 +0200 |
| commit | a1bc030b70ca9f4efdc358af222c664c3ec0b148 (patch) | |
| tree | 3994ab53ef7dd1da291c7d1835dc3f7b78d0a7a4 /compiler/rustc_errors/src | |
| parent | 24138f003472051e1ecdc41c27748a4d0f2e511d (diff) | |
| parent | de644626c3789e62d24bb90873bdc1b41b5f6db2 (diff) | |
| download | rust-a1bc030b70ca9f4efdc358af222c664c3ec0b148.tar.gz rust-a1bc030b70ca9f4efdc358af222c664c3ec0b148.zip | |
Merge from rustc
Diffstat (limited to 'compiler/rustc_errors/src')
| -rw-r--r-- | compiler/rustc_errors/src/diagnostic_impls.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/compiler/rustc_errors/src/diagnostic_impls.rs b/compiler/rustc_errors/src/diagnostic_impls.rs index 4bf7dccab92..662c8a7b8be 100644 --- a/compiler/rustc_errors/src/diagnostic_impls.rs +++ b/compiler/rustc_errors/src/diagnostic_impls.rs @@ -282,6 +282,12 @@ impl IntoDiagArg for ClosureKind { } } +impl IntoDiagArg for hir::def::Namespace { + fn into_diag_arg(self) -> DiagArgValue { + DiagArgValue::Str(Cow::Borrowed(self.descr())) + } +} + #[derive(Clone)] pub struct DiagSymbolList(Vec<Symbol>); |
