| 740 | } |
| 741 | |
| 742 | bool Declaration::hasUses() const |
| 743 | { |
| 744 | ENSURE_CAN_READ |
| 745 | int idx = topContext()->indexForUsedDeclaration(const_cast<Declaration*>(this), false); |
| 746 | bool ret = idx != std::numeric_limits<int>::max() && (idx >= 0 || hasDeclarationUse(topContext(), idx)); //hasLocalUses |
| 747 | DeclarationId myId = id(); |
| 748 | |
| 749 | if (!ret && DUChain::uses()->hasUses(myId)) { |
| 750 | ret = true; |
| 751 | } |
| 752 | |
| 753 | if (!ret && !myId.isDirect() && DUChain::uses()->hasUses(id(true))) { |
| 754 | ret = true; |
| 755 | } |
| 756 | |
| 757 | return ret; |
| 758 | } |
| 759 | |
| 760 | QMap<IndexedString, QVector<KTextEditor::Range>> Declaration::usesCurrentRevision() const |
| 761 | { |
nothing calls this directly
no test coverage detected