Details
-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
Qt Creator 4.9.0-beta1
Description
When calling a method of an instance with wrong parameter type, the instance is not highlighted together with other occurrences of this instance in the scope.
In line 27 the reference to a wrong type lets the Clang Code Model give up in detecting, that that the instance db is actually the db used in the scope: the highlighting is missing that you can see e.g. in line 29.
Refactoring the name of db (e.g. to database) in the screenshot situation also neglects the occurrence of db in line 27. However it is detected, that db in line 27 is not a known type anymore: use of undeclared identifier.
If you put your cursor on db in line 27, the other db occurrences are not highlighted.
If your put line 26 in comment and use the line 25 for the correct type of num, everything works as expected.