Being unable to pay the restaurant bill due to a credit card or debit card declining does happen sometimes and most restaurants are willing to work with you to pay the bill.
In most cases the restaurant will just ask for ID and may take a copy of your ID and have you come back the next day or so and pay the bill either in cash or with the credit or debit card again.
You will not be arrested or anything like that if your debit or credit card is declined and instead the restaurant will allow you to come back later and pay.