summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNathan Ridge2018-09-01 23:55:44 -0400
committerNathan Ridge2018-09-10 23:21:27 -0400
commit567243a752c068badc7f4bbdde837bb60bbabe3f (patch)
tree8a8f6856c54b39f2f325ace6027f8ecbfd93db92
parent0cf1ee7fdece3fd328f69ae69ce9d9396551b975 (diff)
downloadorg.eclipse.cdt-567243a752c068badc7f4bbdde837bb60bbabe3f.tar.gz
org.eclipse.cdt-567243a752c068badc7f4bbdde837bb60bbabe3f.tar.xz
org.eclipse.cdt-567243a752c068badc7f4bbdde837bb60bbabe3f.zip
Bug 538509 - Ensure a lookup point is always set during semantic highlighting
-rw-r--r--core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/SemanticHighlightingReconciler.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/SemanticHighlightingReconciler.java b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/SemanticHighlightingReconciler.java
index ccea383874..4022486f73 100644
--- a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/SemanticHighlightingReconciler.java
+++ b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/SemanticHighlightingReconciler.java
@@ -445,7 +445,12 @@ public class SemanticHighlightingReconciler implements ICReconcilingListener {
* @param visitor the AST visitor
*/
private void reconcilePositions(IASTTranslationUnit ast, PositionCollector visitor) {
- ast.accept(visitor);
+ try {
+ CPPSemantics.pushLookupPoint(ast);
+ ast.accept(visitor);
+ } finally {
+ CPPSemantics.popLookupPoint();
+ }
List<HighlightedPosition> oldPositions= fRemovedPositions;
List<HighlightedPosition> newPositions= new ArrayList<HighlightedPosition>(fNOfRemovedPositions);
for (int i= 0, n= oldPositions.size(); i < n; i ++) {