Add createPropertyDefinition()
This commit is contained in:
parent
d014835c7c
commit
121bb35633
|
@ -835,5 +835,12 @@ namespace de4dot.blocks {
|
|||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static int nextTokenRid = 0x00FFFFFF;
|
||||
public static PropertyDefinition createPropertyDefinition(string name, TypeReference propType) {
|
||||
var propDef = new PropertyDefinition(name, PropertyAttributes.None, propType);
|
||||
propDef.MetadataToken = new MetadataToken(TokenType.Property, nextTokenRid--);
|
||||
return propDef;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user