MCPcopy Create free account
hub / github.com/beefytech/Beef / HasAutoProperty

Method HasAutoProperty

IDEHelper/Compiler/BfSystem.cpp:949–968  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

947}
948
949bool BfTypeDef::HasAutoProperty(BfPropertyDeclaration* propertyDeclaration)
950{
951 if (mTypeCode == BfTypeCode_Interface)
952 return false;
953 if (propertyDeclaration->mTypeRef == NULL)
954 return false;
955 if ((propertyDeclaration->mVirtualSpecifier != NULL) && (propertyDeclaration->mVirtualSpecifier->GetToken() == BfToken_Abstract))
956 return false;
957 if (propertyDeclaration->mExternSpecifier != NULL)
958 return false;
959 if (propertyDeclaration->IsA<BfIndexerDeclaration>())
960 return false;
961
962 for (auto methodDeclaration : propertyDeclaration->mMethods)
963 {
964 if (methodDeclaration->mBody == NULL)
965 return true;
966 }
967 return false;
968}
969
970String BfTypeDef::GetAutoPropertyName(BfPropertyDeclaration* propertyDeclaration)
971{

Callers 3

ProcessMethodMethod · 0.80
VisitMethod · 0.80
LoadPropertyMethod · 0.80

Calls 1

GetTokenMethod · 0.80

Tested by

no test coverage detected