mirror of
https://github.com/intel/llvm.git
synced 2026-02-01 00:46:45 +08:00
Added missing break statement.
Reordered serialization methods for FunctionTypeProto and FunctionTypeNoProto to be alphabetical by serialized type name. llvm-svn: 44130
This commit is contained in:
@@ -72,6 +72,7 @@ void Type::Create(ASTContext& Context, unsigned i, Deserializer& D) {
|
||||
|
||||
case Type::ConstantArray:
|
||||
D.RegisterPtr(PtrID,ConstantArrayType::CreateImpl(Context,D));
|
||||
break;
|
||||
|
||||
case Type::FunctionNoProto:
|
||||
D.RegisterPtr(PtrID,FunctionTypeNoProto::CreateImpl(Context,D));
|
||||
@@ -137,6 +138,18 @@ Type* ConstantArrayType::CreateImpl(ASTContext& Context, Deserializer& D) {
|
||||
// FunctionTypeNoProto
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
void FunctionTypeNoProto::EmitImpl(Serializer& S) const {
|
||||
S.Emit(getResultType());
|
||||
}
|
||||
|
||||
Type* FunctionTypeNoProto::CreateImpl(ASTContext& Context, Deserializer& D) {
|
||||
return Context.getFunctionTypeNoProto(QualType::ReadVal(D)).getTypePtr();
|
||||
}
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
// FunctionTypeProto
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
void FunctionTypeProto::EmitImpl(Serializer& S) const {
|
||||
S.Emit(getResultType());
|
||||
S.EmitBool(isVariadic());
|
||||
@@ -160,18 +173,6 @@ Type* FunctionTypeProto::CreateImpl(ASTContext& Context, Deserializer& D) {
|
||||
NumArgs,isVariadic).getTypePtr();
|
||||
}
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
// FunctionTypeProto
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
void FunctionTypeNoProto::EmitImpl(Serializer& S) const {
|
||||
S.Emit(getResultType());
|
||||
}
|
||||
|
||||
Type* FunctionTypeNoProto::CreateImpl(ASTContext& Context, Deserializer& D) {
|
||||
return Context.getFunctionTypeNoProto(QualType::ReadVal(D)).getTypePtr();
|
||||
}
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
// PointerType
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
Reference in New Issue
Block a user