I mean... they'd be told that that would happen in advance. Wouldn't that then serve as an incentive to avoid making a pattern of taking home the more-expensive food? (They could still do it rarely, though. A one-time $50 bump in spending isn't going to affect your taxes.)
Here, people don't have any money or food stamps "burning a hole in their pocket." They just have their own money, and an unlimited line of credit for grocery stores that would "come due" in the form of taxes at the end of the year (but which would only end up costing them anything-at-all if they tried to live beyond their means.)
The only real presumption I'm making here, IMHO, is that people would be too ashamed to buy the "below your means" items (e.g. rice and beans) on this credit, if they didn't have to. Just like people are usually too ashamed to go to food banks if they don't have to.
I will say I'm not a big fan of using shame to gate off this benefit. my intuition is that shame alone is not enough to stop most people from seeing a way to stretch their grocery budget, if they can use it to buy anything they want. if it is effective, then that's only in proportion to how dehumanizing the experience of using it is, which is also kind of shitty.
That, and perhaps the dollar-cost of your "free" food purchases would be taken into account in calculating your tax bracket.