Cars will never not exist. They should exist less and not interfere with other human friendly modes of transportation. That is a reasonable goal.
That goal requires specific places cars go, and for other people’s safety, people on foot do not.
A highway where (in my state) it is illegal to be walking, is not where the people go.
Thats a bad decision on the person walking and a bad decision by the driver, but fundamentally if you assign cars go quickly from point A to B on highways designed for cars… don’t walk there.