Before this patch, `ParseDiagnosticArgs` can be called with a `nullptr` `DiagnosticsEngine *`. This happens early on in the compilation process, where no proper `DiagnosticEngine` exists, because the diagnostic options (passed through command line) are not known yet.
This patch replaces the nullable pointer with a reference. To simulate the `nullptr` behavior, an ignoring `DiagnosticEngine` is used instead.
Besides simplifying the code, this patch enables a future patch (D84673) that ports diagnostic options to the new marshalling infrastructure.