This caused non-deterministic crashes when a high number of modules
containing diagnostics were compiled for the first time. The 9-entry
test case results in a crash on 64-bit macOS when run under Guard
Malloc without this change.
rdar://problem/33515925