Reporter | Edward Pavlov (edward.pavlov) |
---|---|
Created | Feb 10, 2012 10:34:22 PM |
Updated | Feb 10, 2012 10:34:22 PM |
Priority | Show-stopper |
Type | Unspecified |
Fix versions | No Fix versions |
State | Submitted |
Assignee | Unassigned |
Subsystem | No subsystem |
Affected versions | No Affected versions |
Fixed in build | No Fixed in build |
Build Build 6.1.37.86 (6.1 release build)
public void Foo([NotNull] ParameterInfo parameterInfo)
{
Attribute.GetCustomAttributes(parameterInfo, typeof (SerializableAttribute)).First();
}
MSDN states that Attribute.GetCustomAttributes return value can be null
"An Attribute array that contains the custom attributes applied to element, or an empty array if no such custom attributes exist."
http://msdn.microsoft.com/en-us/library/2fw1se54(VS.90).aspx
public void Foo([NotNull] ParameterInfo parameterInfo)
{
Attribute.GetCustomAttributes(parameterInfo, typeof (SerializableAttribute)).First();
}
MSDN states that Attribute.GetCustomAttributes return value can be null
"An Attribute array that contains the custom attributes applied to element, or an empty array if no such custom attributes exist."
http://msdn.microsoft.com/en-us/library/2fw1se54(VS.90).aspx