Closed FreeApophis closed 1 year ago
The following does not compile with error:
error CS0853: An expression tree may not contain a named argument specification
This real example uses AutoMap:
CreateMap<ArticleWithCalculation, Article>() .ForCtorParam(nameof(Artikel.PriceCalculation), a => a.MapFrom( s => s.Article.Match( none: PriceCalculation.NotFound, some: article => article.CatalogType.ConvertPriceCalculation(): ))
If you remove none and some, it will trigger our λ1003 warning:
warning λ1003: Add argument name for argument 'none'
Solution:
The following does not compile with error:
This real example uses AutoMap:
If you remove none and some, it will trigger our λ1003 warning:
Solution: