• Nikolai Kosjar's avatar
    Editor: Do not highlight invalid Uses · c90815e2
    Nikolai Kosjar authored
    
    
    Invalid Uses (line == 0) are generated by e.g. a Q_D statement.
    
    This kills
     1. the selection artifact in line 0, column 0 and
     2. the warning "QTextCursor::setPosition: Position '-1' out of range"
    
    for the following example code and cursor position:
    
        void f()
        {
            Q_D(x)
            d->hello(); // put the cursor on the 'd'!
        }
    
    Change-Id: I6968cbc261f05e08f71ff125437c8c9e863b475b
    Reviewed-by: default avatarErik Verbruggen <erik.verbruggen@digia.com>
    c90815e2
cppeditor.cpp 82.3 KB