This question established that, if a restaurant is suddenly unable to take all credit cards, and you don't have cash, then it is not a criminal matter and the debt would just be resolved through civil methods.
On the other hand, if you went to a restaurant with only a credit card that you knew full well was a bad card (or any other version of going to a restaurant knowing in advance that you can't pay), this is indeed a crime (theft of services).
But there's a middle case I'm not sure about. I once went to a restaurant, and I gave them two different cards from two different banks. I telephoned both banks directly in front of restaurant staff, and both banks confirmed the cards were good, but the restaurant continued to insist they weren't. After the incident, I continued using both cards, and they both continued to work with no problems.
In my case, I had a third card that inexplicably worked - but supposing I didn't.
I understand that the key issue is whether I had an intent beforehand to take food without paying, and I obviously know that I had no such intention. But now there is a dispute over whether I can prove what my intent was, and even though I was telling the truth, I can (sort of) understand that the restaurant (and the police) wouldn't necessarily take my word for it. Could this have been a criminal matter?
Footnote: The actual incident was regarding a prepaid to-go order, so I probably would have just not received the food. But let's assume the hypothetical version wasn't prepaid.