diff --git a/Mono.Cecil/GenericParameter.cs b/Mono.Cecil/GenericParameter.cs index 30dd73382..de746449b 100644 --- a/Mono.Cecil/GenericParameter.cs +++ b/Mono.Cecil/GenericParameter.cs @@ -165,6 +165,11 @@ public bool HasDefaultConstructorConstraint { set { attributes = attributes.SetAttributes ((ushort) GenericParameterAttributes.DefaultConstructorConstraint, value); } } + public bool AllowByRefLikeConstraint { + get { return attributes.GetAttributes ((ushort) GenericParameterAttributes.AllowByRefLikeConstraint); } + set { attributes = attributes.SetAttributes ((ushort) GenericParameterAttributes.AllowByRefLikeConstraint, value); } + } + #endregion public GenericParameter (IGenericParameterProvider owner) diff --git a/Mono.Cecil/GenericParameterAttributes.cs b/Mono.Cecil/GenericParameterAttributes.cs index 149582cdb..51f094f47 100644 --- a/Mono.Cecil/GenericParameterAttributes.cs +++ b/Mono.Cecil/GenericParameterAttributes.cs @@ -22,6 +22,7 @@ public enum GenericParameterAttributes : ushort { SpecialConstraintMask = 0x001c, ReferenceTypeConstraint = 0x0004, NotNullableValueTypeConstraint = 0x0008, - DefaultConstructorConstraint = 0x0010 + DefaultConstructorConstraint = 0x0010, + AllowByRefLikeConstraint = 0x0020, } }