Validate crate name in CLI option --extern

This commit is contained in:
León Orell Valerian Liehr 2023-08-18 13:23:53 +02:00
parent f0727758d1
commit 8d81d5a909
No known key found for this signature in database
GPG key ID: D17A07215F68E713
15 changed files with 60 additions and 17 deletions

View file

@ -1710,6 +1710,15 @@ impl EarlyErrorHandler {
self.handler.struct_fatal(msg).emit()
}
#[allow(rustc::untranslatable_diagnostic)]
#[allow(rustc::diagnostic_outside_of_impl)]
pub(crate) fn early_struct_error(
&self,
msg: impl Into<DiagnosticMessage>,
) -> DiagnosticBuilder<'_, !> {
self.handler.struct_fatal(msg)
}
#[allow(rustc::untranslatable_diagnostic)]
#[allow(rustc::diagnostic_outside_of_impl)]
pub fn early_warn(&self, msg: impl Into<DiagnosticMessage>) {