Reporter | Artem Votincev (Artem.Votincev) |
---|---|
Created | Apr 7, 2011 1:06:01 PM |
Updated | Apr 13, 2018 5:39:44 PM |
Subsystem | Quick Fixes |
Assignee | Alisa Afonina (alisa.afonina) |
Priority | Normal |
State | Submitted |
Type | Bug |
Fix version | Backlog |
Affected versions | 2018.1, 5.1.3 |
Fixed In Version ReSharper | Undefined |
VsVersion | All Versions |
Please see attached Program.cs file
In this file please check the following lines:
//// Resharper suggest to remove 2nd parameter
productService.Setup(a => a.FailMethod(true, false));
//// Compilation faild on this method
productService.Setup(a => a.FailMethod(true));
FailMethod is a method with not required parameter with default value = false.
Error in compilation log:
An expression tree may not contain a call or invocation that uses optional arguments
In this file please check the following lines:
//// Resharper suggest to remove 2nd parameter
productService.Setup(a => a.FailMethod(true, false));
//// Compilation faild on this method
productService.Setup(a => a.FailMethod(true));
FailMethod is a method with not required parameter with default value = false.
Error in compilation log:
An expression tree may not contain a call or invocation that uses optional arguments