completion: wrap expression visitor into a read lock

Authored by brauch on Jan 14 2017, 12:19 PM.

Description

completion: wrap expression visitor into a read lock

Unlike in the parse job, we do not hold the parse lock for the context
which is passed to the expression visitor. Thus, it might be modified
or deleted by a parse job while we're passing the pointer around. This
means that after data is taken out of the DUContextPointer, the read
lock must not be released again while the object is in use.

Likely the reason for occasional crashes in completion in some situations.
BUG:374097

Details

Committed
brauchJan 14 2017, 12:19 PM
Parents
R53:301ca47f8fb4: Fix off-by-one bug in negative tuple indexing.
Branches
Unknown
Tags
Unknown