The @a selector (but only without a radius/area defined via r/rx/ry/rz) will include dead players in the next snapshot. All other selectors work as intended.
The target entity is "dead" during its death phase, therefore cannot be targeted because @e is not allowed to target dead entities.
Via MC-46223:
The target entity is "dead" during its death phase, therefore cannot be targeted because @e is not allowed to target dead entities.