[ty] Share attribute write compatibility checks (#28555)
## Summary
We move attribute-write compatibility checking from `protocol_class.rs`
to `attribute_write.rs`, alongside the lookup and descriptor-setter
helpers it uses. This makes the same write checks available to nominal
attribute override validation.
Protocol checking continues to use the active type relation and
constraints. Descriptor setters, `Self` binding, class and instance
fallbacks, and terminal `__setattr__` behavior are unchanged.
Part of https://github.com/astral-sh/ty/issues/2158.