postsharp / Metalama

Metalama is a Roslyn-based meta-programming framework. Use this repo to report bugs or ask questions.
164 stars 4 forks source link

EligibilityExtensions.If does not fail when the condition is not met #188

Closed gfraiteur closed 11 months ago

gfraiteur commented 11 months ago

In a condition like this:

    builder.If( t => t.Attributes.OfAttributeType(typeof(MyAttribute)).Any()).MustSatisfy( t=> t.Attributes.OfAttributeType(typeof(MyAttribute)).First().ConstructorArguments.Length >= 3, x => $"The MyAttribute must have at least 3 arguments");

Then if the condition of the MustSatisfy fails the whole If does not fail.

PostSharpBot commented 11 months ago

Hello @gfraiteur, thank you for submitting this issue. We will try to get back to you as soon as possible. Note to the PostSharp team, this ticket is being tracked in our dashboard under ID TP-33571.

gfraiteur commented 11 months ago

Solved in Solved in 2023.3.1-preview..