[ty] Avoid crashes when negating recursive aliases (#29429)
Negating a recursive legacy type alias such as `A: TypeAlias =
"list[Not[A] | A]"` could repeatedly expand the alias until ty crashed.
Preserve recursive alias identity when constructing negations and
simplify an exact static complement pair, so indexing an `A` now reveals
`object`.
Closes astral-sh/ty#4728.
Stacked on #29427.