[clang][deps] Remove the `finalize()` API for by-module-name scans (#184232)
The `DiagnosticConsumer::finish()` API was removed in #183831. Since
that was the only thing the by-module-name `finalize()` API called, we
can safely remove that and simplify the scanner.