Nope, I’m afraid not. The only things you can do with constraints are:
where T : class– T must be a reference typewhere T : struct– T must be a non-nullable value typewhere T : SomeClass– T must be SomeClass or derive from itwhere T : ISomeInterface– T must be ISomeInterface or implement itwhere T : new()– T must have a public parameterless constructor
Various combinations are feasible, but not all. Nothing about attributes.