mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-09 03:52:19 +02:00
Allow IOnTypeInit for method declarations
This commit is contained in:
parent
35584ef288
commit
3b412719fe
4 changed files with 78 additions and 25 deletions
|
@ -22146,9 +22146,17 @@ void BfModule::GetMethodCustomAttributes(BfMethodInstance* methodInstance)
|
|||
{
|
||||
if (methodInstance->GetMethodInfoEx()->mMethodCustomAttributes == NULL)
|
||||
methodInstance->mMethodInfoEx->mMethodCustomAttributes = new BfMethodCustomAttributes();
|
||||
methodInstance->mMethodInfoEx->mMethodCustomAttributes->mCustomAttributes = GetCustomAttributes(attributeDirective, attrTarget);
|
||||
}
|
||||
|
||||
if ((methodInstance == methodInstance->mMethodInstanceGroup->mDefault) && (methodInstance->mMethodInstanceGroup->mDefaultCustomAttributes != NULL))
|
||||
{
|
||||
// Take over prevoiusly-generated custom attributes
|
||||
methodInstance->mMethodInfoEx->mMethodCustomAttributes->mCustomAttributes = methodInstance->mMethodInstanceGroup->mDefaultCustomAttributes;
|
||||
methodInstance->mMethodInstanceGroup->mDefaultCustomAttributes = NULL;
|
||||
}
|
||||
else
|
||||
methodInstance->mMethodInfoEx->mMethodCustomAttributes->mCustomAttributes = GetCustomAttributes(attributeDirective, attrTarget);
|
||||
}
|
||||
|
||||
if ((propertyMethodDeclaration != NULL) && (propertyMethodDeclaration->mPropertyDeclaration->mAttributes != NULL) && ((attrTarget & BfAttributeTargets_Property) == 0))
|
||||
{
|
||||
if (methodInstance->GetMethodInfoEx()->mMethodCustomAttributes != NULL)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue