I live in a city where the bicycle paths on walkways are so bad that this distinction is hardly there — I certainly know I would take a well sized lane over a narrow, indistinguishable from the walkway with missing bricks and tree roots every day of the week, especially in pedestrian-heavy areas.
But that balance heavily depends on the city, how well behaved motorists are there, how crossings are implemented how many pedestrians are there and (in my case) which material was chosen for the non-street bicycle paths. In my city they used slightly darker bricks and no bicycle symbols — that is basically indistinguishable from the rest of the walkway for pedestrians and after a few years those bricks have the tendency to present you with a bone-shaking surface.
Safety is important and you are correct that painted on lanes kill more cyclists, but safety is not the only metric, comfort is also important or how uninterrupted you can ride, how stressful interaction with other people is, etc. And in a city with a ton of pedestrians and uncomfortable bicycle paths on walkways you need to be more on alert there than on the road.
TL;DR: Which one is better cannot be answered for every case without knowing the context.