This is also why taking about a country's debt is often more complicated than people think. Because when I go into debt on my credit card or whatever, that's bad because the credit card company starts feeding on me.
But when a properly functioning government goes into debt, it's to me! What I get out of it is a bridge or train or something now, greater economic opportunities associated with that, and then also I get my money back later with interest, so it gives me a reliable way to grow my own money. Or, like I said, for banks or investment firms on my behalf to use these tools as some of the tools in the box to grow both my and their money.
It's only a problem when the debt gets to the point that it doesn't seem like the country will be able to pay it. Or, similarly, when the investment in infrastructure doesn't produce enough extra value to fund this repayment.
But again, when a government is in debt, it's in debt to investors who are using that debt to grow their money while the (well-functioning) government is using the money to grow the country.