Fix crashes when document gets destroyed directly after load

Authored by mwolff on Oct 21 2018, 6:12 PM.

Description

Fix crashes when document gets destroyed directly after load

This fixes the clang code completion unit test, which used to
crash on exit since the event loop wasn't run between loading
a document and destroying it again.

To guard against this, we need to jump through a QPointer hoop,
which requires some lambda boiler plate but otherwise isn't too bad.

Details

Committed
mwolffOct 21 2018, 6:12 PM
Parents
R32:65c75e0c4f19: Merge branch '5.3'
Branches
Unknown
Tags
Unknown