Commit 566ae4cc authored by Leandro Melo's avatar Leandro Melo Committed by Tobias Hunger

Add comment for clarification

Change-Id: I18f35a6682a3fc26bbff51f4371d7e777541792d
Reviewed-on: default avatarQt Sanity Bot <>
Reviewed-by: default avatarTobias Hunger <>
parent e5a42e2d
......@@ -377,6 +377,10 @@ CompletionAssistProvider *CodeAssistantPrivate::identifyActivationSequence()
if (length == 0)
QString sequence = m_textEditor->textAt(m_textEditor->position() - length, length);
// In pretty much all cases the sequence will have the appropriate length. Only in the
// case of typing the very first characters in the document for providers that request a
// length greater than 1 (currently only C++, which specifies 3), the sequence needs to
// be preprended so it has the expected length.
const int lengthDiff = length - sequence.length();
for (int j = 0; j < lengthDiff; ++j)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment