Category "design-time"

c# check value at design time

Is there any way, perhaps by use of Contracts, to check whether a variable's value conforms to some rules during design time in Visual Studio 2022? I.e. int is