Deleted Added
full compact
CodeCompleteConsumer.cpp (218893) CodeCompleteConsumer.cpp (221345)
1//===--- CodeCompleteConsumer.cpp - Code Completion Interface ---*- C++ -*-===//
2//
3// The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//

--- 361 unchanged lines hidden (view full) ---

370 }
371 }
372}
373
374void CodeCompletionResult::computeCursorKindAndAvailability() {
375 switch (Kind) {
376 case RK_Declaration:
377 // Set the availability based on attributes.
1//===--- CodeCompleteConsumer.cpp - Code Completion Interface ---*- C++ -*-===//
2//
3// The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//

--- 361 unchanged lines hidden (view full) ---

370 }
371 }
372}
373
374void CodeCompletionResult::computeCursorKindAndAvailability() {
375 switch (Kind) {
376 case RK_Declaration:
377 // Set the availability based on attributes.
378 Availability = CXAvailability_Available;
379 if (Declaration->getAttr<UnavailableAttr>())
380 Availability = CXAvailability_NotAvailable;
381 else if (Declaration->getAttr<DeprecatedAttr>())
378 switch (Declaration->getAvailability()) {
379 case AR_Available:
380 case AR_NotYetIntroduced:
381 Availability = CXAvailability_Available;
382 break;
383
384 case AR_Deprecated:
382 Availability = CXAvailability_Deprecated;
385 Availability = CXAvailability_Deprecated;
386 break;
383
387
388 case AR_Unavailable:
389 Availability = CXAvailability_NotAvailable;
390 break;
391 }
392
384 if (FunctionDecl *Function = dyn_cast<FunctionDecl>(Declaration))
385 if (Function->isDeleted())
386 Availability = CXAvailability_NotAvailable;
387
388 CursorKind = getCursorKindForDecl(Declaration);
389 if (CursorKind == CXCursor_UnexposedDecl)
390 CursorKind = CXCursor_NotImplemented;
391 break;

--- 69 unchanged lines hidden ---
393 if (FunctionDecl *Function = dyn_cast<FunctionDecl>(Declaration))
394 if (Function->isDeleted())
395 Availability = CXAvailability_NotAvailable;
396
397 CursorKind = getCursorKindForDecl(Declaration);
398 if (CursorKind == CXCursor_UnexposedDecl)
399 CursorKind = CXCursor_NotImplemented;
400 break;

--- 69 unchanged lines hidden ---