When it comes to bankruptcy, not all debts are created equal. The law recognizes different classes of obligations. You'll have to make good on those that are secured or given priority. You may be able to discharge some non-priority unsecured debts if you find yourself in the unfortunate position of declaring bankruptcy.
A debt is secured when it is backed with collateral. For instance, when you take out a mortgage to buy a house, the house acts as collateral. An unsecured debt has no such support, and the court will give them either priority and non-priority status.
Priorities Under Bankruptcy Law
Child support, payroll taxes and spousal support are given priority because, according to alllaw.com, it's either money owed to the government, or it suits the public good. Those must be paid even if you declare bankruptcy. Other unsecured obligations, like credit card bills, personal loans and medical bills, fall under non-priority because they're personal. The law allows these to be discharged in bankruptcy.