[cfe-commits] r45609 - /cfe/trunk/AST/StmtSerialization.cpp
Ted Kremenek
kremenek at apple.com
Fri Jan 4 16:57:49 PST 2008
Author: kremenek
Date: Fri Jan 4 18:57:49 2008
New Revision: 45609
URL: http://llvm.org/viewvc/llvm-project?rev=45609&view=rev
Log:
Moved serialization code for ObjcForCollectionStmt to be in alphabetical order
with the rest of the Objective-C serialization code.
Modified:
cfe/trunk/AST/StmtSerialization.cpp
Modified: cfe/trunk/AST/StmtSerialization.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/AST/StmtSerialization.cpp?rev=45609&r1=45608&r2=45609&view=diff
==============================================================================
--- cfe/trunk/AST/StmtSerialization.cpp (original)
+++ cfe/trunk/AST/StmtSerialization.cpp Fri Jan 4 18:57:49 2008
@@ -94,9 +94,6 @@
case ForStmtClass:
return ForStmt::CreateImpl(D);
-
- case ObjcForCollectionStmtClass:
- return ObjcForCollectionStmt::CreateImpl(D);
case GotoStmtClass:
return GotoStmt::CreateImpl(D);
@@ -174,6 +171,9 @@
case ObjCEncodeExprClass:
return ObjCEncodeExpr::CreateImpl(D);
+ case ObjcForCollectionStmtClass:
+ return ObjcForCollectionStmt::CreateImpl(D);
+
case ObjCIvarRefExprClass:
return ObjCIvarRefExpr::CreateImpl(D);
@@ -563,21 +563,6 @@
return new ForStmt(Init,Cond,Inc,Body,ForLoc);
}
-void ObjcForCollectionStmt::EmitImpl(Serializer& S) const {
- S.Emit(ForLoc);
- S.EmitOwnedPtr(getElement());
- S.EmitOwnedPtr(getCollection());
- S.EmitOwnedPtr(getBody());
-}
-
-ObjcForCollectionStmt* ObjcForCollectionStmt::CreateImpl(Deserializer& D) {
- SourceLocation ForLoc = SourceLocation::ReadVal(D);
- Stmt* Element = D.ReadOwnedPtr<Stmt>();
- Expr* Collection = D.ReadOwnedPtr<Expr>();
- Stmt* Body = D.ReadOwnedPtr<Stmt>();
- return new ObjcForCollectionStmt(Element,Collection,Body,ForLoc);
-}
-
void GotoStmt::EmitImpl(Serializer& S) const {
S.Emit(GotoLoc);
S.Emit(LabelLoc);
@@ -934,6 +919,21 @@
return new ObjCEncodeExpr(T,ET,AtLoc,RParenLoc);
}
+void ObjcForCollectionStmt::EmitImpl(Serializer& S) const {
+ S.Emit(ForLoc);
+ S.EmitOwnedPtr(getElement());
+ S.EmitOwnedPtr(getCollection());
+ S.EmitOwnedPtr(getBody());
+}
+
+ObjcForCollectionStmt* ObjcForCollectionStmt::CreateImpl(Deserializer& D) {
+ SourceLocation ForLoc = SourceLocation::ReadVal(D);
+ Stmt* Element = D.ReadOwnedPtr<Stmt>();
+ Expr* Collection = D.ReadOwnedPtr<Expr>();
+ Stmt* Body = D.ReadOwnedPtr<Stmt>();
+ return new ObjcForCollectionStmt(Element,Collection,Body,ForLoc);
+}
+
void ObjCIvarRefExpr::EmitImpl(Serializer& S) const {
S.Emit(Loc);
S.Emit(getType());
More information about the cfe-commits
mailing list