diff --git a/src/errors.rs b/src/errors.rs index 5b311342392..6bada3d334c 100644 --- a/src/errors.rs +++ b/src/errors.rs @@ -96,7 +96,7 @@ fn into_diag(self, dcx: DiagCtxtHandle<'_>, level: Level) -> Diag<'_, G> { diag.span(span); }; if let Some(missing_features) = self.missing_features { - diag.subdiagnostic(dcx, missing_features); + diag.subdiagnostic(missing_features); } diag.arg("features", self.features.join(", ")); diag