Deleted Added
full compact
DeclBase.cpp (204643) DeclBase.cpp (204793)
1//===--- DeclBase.cpp - Declaration AST Node Implementation ---------------===//
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//===----------------------------------------------------------------------===//

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

41const char *Decl::getDeclKindName() const {
42 switch (DeclKind) {
43 default: assert(0 && "Declaration not in DeclNodes.def!");
44#define DECL(Derived, Base) case Derived: return #Derived;
45#include "clang/AST/DeclNodes.def"
46 }
47}
48
1//===--- DeclBase.cpp - Declaration AST Node Implementation ---------------===//
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//===----------------------------------------------------------------------===//

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

41const char *Decl::getDeclKindName() const {
42 switch (DeclKind) {
43 default: assert(0 && "Declaration not in DeclNodes.def!");
44#define DECL(Derived, Base) case Derived: return #Derived;
45#include "clang/AST/DeclNodes.def"
46 }
47}
48
49void Decl::setInvalidDecl(bool Invalid) {
50 InvalidDecl = Invalid;
51 if (Invalid) {
52 // Defensive maneuver for ill-formed code: we're likely not to make it to
53 // a point where we set the access specifier, so default it to "public"
54 // to avoid triggering asserts elsewhere in the front end.
55 setAccess(AS_public);
56 }
57}
58
49const char *DeclContext::getDeclKindName() const {
50 switch (DeclKind) {
51 default: assert(0 && "Declaration context not in DeclNodes.def!");
52#define DECL(Derived, Base) case Decl::Derived: return #Derived;
53#include "clang/AST/DeclNodes.def"
54 }
55}
56

--- 886 unchanged lines hidden ---
59const char *DeclContext::getDeclKindName() const {
60 switch (DeclKind) {
61 default: assert(0 && "Declaration context not in DeclNodes.def!");
62#define DECL(Derived, Base) case Decl::Derived: return #Derived;
63#include "clang/AST/DeclNodes.def"
64 }
65}
66

--- 886 unchanged lines hidden ---