Every mile you can squeeze out of a older vehicle will be cheaper than a new vehicle even with most repairs. When you sell a usable car, you are selling the use remaining in that vehicle and it is often for less than you acquired if for. When buying new/newer frequently, you are buying that "worry free" idea... which is not a real product nor is it guaranteed. If anything, that is just an attempt to guard against uncertainty. Mechanical parts fail, but most fail about at a certain time depending on the design. So making sure that your component are "younger" than that point is paying for that "worry-free" but thing can fail before that point. Still, it is a mechanical item so those parts can be replaced and you "reset" that item. What folks forget is that when you buy or sell a car, you are setting the value. So if someone has a $10K car or a 1K car which might need a new transmission, if folks think "it cost more than the car is worth" is making a huge error because unless the item is sold, the item has no real worth. So having a $1K car with a repaired transmission is still cheaper than buying a newer car and since you are not "selling" the cheaper repaired car, repairing for more than it is worth is mute because if it is not for sale, it has not real "worth". Repairing the $10K compared to its worth is also mute as unless you sell the car, repair to worth is mute. Value is not set until the sale. Thus, what you have to look at is the cost per mile and many "younger" cars can never win this metric. (You can toss safety into this and things might be a lot different). If you get a 150K car for $3,000 (ignoring fuel, tax, fees, insurance, repair etc) and drive it to 200K, it is $0.06 per mile. If you buy a $20,000, you have to drive it over 300K to get the same cost/benefit. You have to crunch the numbers. Now, will I pay for the "worry-free" option... for my wife yes because she panics like the world will end if the low tire pressure monitoring gauge comes on. Just not have her being a nervous ball of anxiousness is worth paying premium... for some. However, calling it the "smart" option is a bit daft. It is a luxury at best.
Now if the vehicle is constantly acting up and it is major repair bill after major repair bill, then yes, time to get rid of it. When a well-kept 91K 2006 Chrysler kept hitting a family member's wallet for 1500+, then yeah, consider it. When after 4K in repairs and the next bill was estimated to be 2.4K, then it was taken to the Toyota dealership for "trade". The cost per mile was increase astronomically here. That is the time were a older car might have outlived its usefulness. Now major rust to the unibody or frame is also a killer in my opinion. That is how my '79 Datsun was eventually sold for parts. Still, it lasted 29 years and 361 days from purchase and was as reliable as could have been.
15 years old isn't that old
Average age of the US auto is about 11 years now. You could drive that Camry for another 15 years and be worry free as well. There is no guarantee that a new vehicle will not leave you stranded... they just cover the cost of the repair for X many miles/years. That is what happened with the '06 Chrysler... the older 15 year old car was much more reliable than the Chrysler junk.
The bigger challenge with 15yo+ cars can be finding parts depending on the popularity of the model. My '01 MR2 had a production run of about 20K units over 6 years (Corollas sell over 200K in a month). Finding parts for the MR2 can be a chase, even at the Toyota Dealership. However, unless you have something even rarer than my MR2 then you are normally in good shape until that 25 year mark and then it gets a bit more dicey.