Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Class/property level attributes are not all copied during repack when AttributeUsageAttribute is inherited from a base type #249

Open
purnellsh opened this issue Apr 26, 2019 · 1 comment

Comments

@purnellsh
Copy link

purnellsh commented Apr 26, 2019

If a specific property of a class has multiple attributes of the same type, and the "AttributeUsageAttribute" is inherited from a base type, then the "AllowMultiple" value of the "AttributeUsageAttribute" that was inherited is not honored. Instead, only 1 attribute of that type is copied by default in ILRepack.

When ILMerge is used, the default behavior is to copy all of these Class level attributes when the inherited "AttributeUsageAttribute" that is set in a base type has "AllowMultiple" set.

Can we get ILRepack to behave more like ILMerge in how it handles class/property level attributes?

@purnellsh
Copy link
Author

I was wrong about the /copyattr and /allowMultiple flags, these did not change the behavior on my class/property level attributes during repack. I found instead that the "AttributeUsageAttribute" is not honored in ILRepack when it is inherited from a base type. This seems to be the source of this difference in behavior from ILMerge to ILRepack.

@purnellsh purnellsh changed the title Class/property level attributes are not all copied by default during repack Class/property level attributes are not all copied by default during repack when AttributeUsageAttribute is inherited from a base type Apr 29, 2019
@purnellsh purnellsh changed the title Class/property level attributes are not all copied by default during repack when AttributeUsageAttribute is inherited from a base type Class/property level attributes are not all copied during repack when AttributeUsageAttribute is inherited from a base type Apr 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant