[cfe-commits] r42601 - in /cfe/trunk: AST/Decl.cpp Sema/SemaDecl.cpp

Fariborz Jahanian fjahanian at apple.com
Wed Oct 3 17:45:27 PDT 2007


Author: fjahanian
Date: Wed Oct  3 19:45:27 2007
New Revision: 42601

URL: http://llvm.org/viewvc/llvm-project?rev=42601&view=rev
Log:
Fixed tabs in couple of sources.

Modified:
    cfe/trunk/AST/Decl.cpp
    cfe/trunk/Sema/SemaDecl.cpp

Modified: cfe/trunk/AST/Decl.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/AST/Decl.cpp?rev=42601&r1=42600&r2=42601&view=diff

==============================================================================
--- cfe/trunk/AST/Decl.cpp (original)
+++ cfe/trunk/AST/Decl.cpp Wed Oct  3 19:45:27 2007
@@ -76,7 +76,7 @@
 
 bool Decl::CollectingStats(bool enable) {
   if (enable) StatSwitch = true;
-	return StatSwitch;
+    return StatSwitch;
 }
 
 void Decl::PrintStats() {
@@ -263,7 +263,7 @@
 FieldDecl* RecordDecl::getMember(IdentifierInfo *name) {
   if (Members == 0 || NumMembers < 0)
     return 0;
-	
+  
   // linear search. When C++ classes come along, will likely need to revisit.
   for (int i = 0; i < NumMembers; ++i) {
     if (Members[i]->getIdentifier() == name)
@@ -305,7 +305,7 @@
 /// Ivars into ObjcImplementationDecl's fields.
 ///
 void ObjcImplementationDecl::ObjcAddInstanceVariablesToClassImpl(
-			       ObjcIvarDecl **ivars, unsigned numIvars) {
+			      ObjcIvarDecl **ivars, unsigned numIvars) {
   NumIvars = numIvars;
   if (numIvars) {
     Ivars = new ObjcIvarDecl*[numIvars];

Modified: cfe/trunk/Sema/SemaDecl.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/Sema/SemaDecl.cpp?rev=42601&r1=42600&r2=42601&view=diff

==============================================================================
--- cfe/trunk/Sema/SemaDecl.cpp (original)
+++ cfe/trunk/Sema/SemaDecl.cpp Wed Oct  3 19:45:27 2007
@@ -100,11 +100,11 @@
 /// getObjcProtocolDecl - Look up a for a protocol declaration in the scope.
 /// return 0 if one not found.
 ObjcProtocolDecl *Sema::getObjCProtocolDecl(Scope *S,
-                       			    IdentifierInfo *Id, 
-				            SourceLocation IdLoc) {
+                                            IdentifierInfo *Id, 
+                                            SourceLocation IdLoc) {
   // Note that Protocols have their own namespace.
   ScopedDecl *PrDecl = LookupScopedDecl(Id, Decl::IDNS_Protocol, 
-				        IdLoc, S);
+                                        IdLoc, S);
   if (PrDecl && !isa<ObjcProtocolDecl>(PrDecl))
     PrDecl = 0;
   return cast_or_null<ObjcProtocolDecl>(static_cast<Decl*>(PrDecl));
@@ -956,7 +956,7 @@
   /// Check then save referenced protocols
   for (unsigned int i = 0; i != NumProtocols; i++) {
     ObjcProtocolDecl* RefPDecl = getObjCProtocolDecl(S, ProtocolNames[i], 
-						     ClassLoc);
+                                                     ClassLoc);
     if (!RefPDecl || RefPDecl->isForwardDecl())
       Diag(ClassLoc, diag::err_undef_protocolref,
            ProtocolNames[i]->getName(),
@@ -968,7 +968,7 @@
 }
 
 Sema::DeclTy *Sema::ActOnStartProtocolInterface(Scope* S,
-		SourceLocation AtProtoInterfaceLoc,
+                SourceLocation AtProtoInterfaceLoc,
                 IdentifierInfo *ProtocolName, SourceLocation ProtocolLoc,
                 IdentifierInfo **ProtoRefNames, unsigned NumProtoRefs) {
   assert(ProtocolName && "Missing protocol identifier");
@@ -995,10 +995,10 @@
   /// Check then save referenced protocols
   for (unsigned int i = 0; i != NumProtoRefs; i++) {
     ObjcProtocolDecl* RefPDecl = getObjCProtocolDecl(S, ProtoRefNames[i], 
-						     ProtocolLoc);
+                                                     ProtocolLoc);
     if (!RefPDecl || RefPDecl->isForwardDecl())
       Diag(ProtocolLoc, diag::err_undef_protocolref,
-	   ProtoRefNames[i]->getName(),
+           ProtoRefNames[i]->getName(),
            ProtocolName->getName());
     PDecl->setReferencedProtocols((int)i, RefPDecl);
   }
@@ -1032,7 +1032,7 @@
 }
 
 Sema::DeclTy *Sema::ActOnStartCategoryInterface(Scope* S,
-		      SourceLocation AtInterfaceLoc,
+                      SourceLocation AtInterfaceLoc,
                       IdentifierInfo *ClassName, SourceLocation ClassLoc,
                       IdentifierInfo *CategoryName, SourceLocation CategoryLoc,
                       IdentifierInfo **ProtoRefNames, unsigned NumProtoRefs) {
@@ -1064,10 +1064,10 @@
   /// Check then save referenced protocols
   for (unsigned int i = 0; i != NumProtoRefs; i++) {
     ObjcProtocolDecl* RefPDecl = getObjCProtocolDecl(S, ProtoRefNames[i], 
-						     CategoryLoc);
+                                                     CategoryLoc);
     if (!RefPDecl || RefPDecl->isForwardDecl())
       Diag(CategoryLoc, diag::err_undef_protocolref,
-	   ProtoRefNames[i]->getName(),
+           ProtoRefNames[i]->getName(),
            CategoryName->getName());
     CDecl->setCatReferencedProtocols((int)i, RefPDecl);
   }
@@ -1517,7 +1517,7 @@
   if (isa<RecordDecl>(static_cast<Decl *>(TagDecl)))
     NewFD = new FieldDecl(Loc, II, T);
   else if (isa<ObjcInterfaceDecl>(static_cast<Decl *>(TagDecl))
-	   || isa<ObjcImplementationDecl>(static_cast<Decl *>(TagDecl)))
+           || isa<ObjcImplementationDecl>(static_cast<Decl *>(TagDecl)))
     NewFD = new ObjcIvarDecl(Loc, II, T);
   else
     assert(0 && "Sema::ActOnField(): Unknown TagDecl");
@@ -1541,7 +1541,7 @@
 }
 
 void Sema::ActOnFields(Scope* S,
-		       SourceLocation RecLoc, DeclTy *RecDecl,
+                       SourceLocation RecLoc, DeclTy *RecDecl,
                        DeclTy **Fields, unsigned NumFields,
                        tok::ObjCKeywordKind *visibility) {
   Decl *EnclosingDecl = static_cast<Decl*>(RecDecl);
@@ -1591,10 +1591,10 @@
     // C99 6.7.2.1p2 - A field may not be an incomplete type except...
     if (FDTy->isIncompleteType()) {
       if (!Record) {  // Incomplete ivar type is always an error.
-	Diag(FD->getLocation(), diag::err_field_incomplete, FD->getName());
+        Diag(FD->getLocation(), diag::err_field_incomplete, FD->getName());
         FD->setInvalidDecl();
         EnclosingDecl->setInvalidDecl();
-	continue;
+        continue;
       }
       if (i != NumFields-1 ||                   // ... that the last member ...
           Record->getKind() != Decl::Struct ||  // ... of a structure ...
@@ -1637,7 +1637,7 @@
           // as an extension.
           Diag(FD->getLocation(), diag::ext_flexible_array_in_struct,
                FD->getName());
-	  if (Record)
+          if (Record)
             Record->setHasFlexibleArrayMember(true);
         }
       }
@@ -1676,7 +1676,7 @@
         ObjcAddInstanceVariablesToClass(ClsFields, RecFields.size());
     else if (isa<ObjcImplementationDecl>(static_cast<Decl*>(RecDecl))) {
       ObjcImplementationDecl* IMPDecl = 
-	cast<ObjcImplementationDecl>(static_cast<Decl*>(RecDecl));
+        cast<ObjcImplementationDecl>(static_cast<Decl*>(RecDecl));
       assert(IMPDecl && "ActOnFields - missing ObjcImplementationDecl");
       IMPDecl->ObjcAddInstanceVariablesToClassImpl(ClsFields, RecFields.size());
       CheckImplementationIvars(IMPDecl, ClsFields, RecFields.size());
@@ -1763,17 +1763,17 @@
   for (unsigned i = 0; i < Sel.getNumArgs(); i++) {
     // FIXME: arg->AttrList must be stored too!
     ParmVarDecl* Param = new ParmVarDecl(SourceLocation(/*FIXME*/), ArgNames[i], 
-					 QualType::getFromOpaquePtr(ArgTypes[i]), 
-					 VarDecl::None, 0);
+                              QualType::getFromOpaquePtr(ArgTypes[i]), 
+                              VarDecl::None, 0);
     Params.push_back(Param);
   }
   QualType resultDeclType = QualType::getFromOpaquePtr(ReturnType);
   ObjcMethodDecl* ObjcMethod =  new ObjcMethodDecl(MethodLoc, Sel,
                                       resultDeclType, 0, -1, AttrList, 
                                       MethodType == tok::minus,
-				      MethodDeclKind == tok::objc_optional ? 
-				      ObjcMethodDecl::Optional : 
-				      ObjcMethodDecl::Required);
+                                      MethodDeclKind == tok::objc_optional ? 
+                                      ObjcMethodDecl::Optional : 
+                                      ObjcMethodDecl::Required);
   ObjcMethod->setMethodParams(&Params[0], Sel.getNumArgs());
   return ObjcMethod;
 }





More information about the cfe-commits mailing list