driver: Fix -fdefer-diagnostics flag
The withDeferredDiagnostics
wrapper wasn't doing anything because the
session it was modifying wasn't used in hsc_env. Therefore the fix is
simple, just push the getSession
call into the scope of
withDeferredDiagnostics
.
Fixes #22391 (closed)