Reporter | Dave Harris (dbharris) |
---|---|
Created | Dec 23, 2010 12:29:16 AM |
Updated | Jan 2, 2012 1:22:18 AM |
Priority | Normal |
Type | Feature |
Fix versions | No Fix versions |
State | Submitted |
Assignee | Evgeny Pasynkov (pasynkov) |
Subsystem | Code Analysis |
Affected versions | 5.1.1 |
Fixed in build | No Fixed in build |
Every now and again I run across code where somebody has marked a non-var type parameter as "ref" perhaps thinking that this was needed because one of the members is altered. If a non-virtual function doesn't actually modify the value of the parameter or in turn pass it as a ref/out to another function, then the ref is wasteful - and potentially confusing. Seems like it would be a relatively easy one to catch and report on.