It's worth noting that a feature like this has been discussed as an extension to parameterized extensions (see the Future Directions section) where it would be spelled as:
extension<T: A> T: B {
// Implementation for `B`
}
Note that parameterized extensions are themselves not yet a part of the language, so even if this direction were pursued it would be a long way off.