Gmail already does this - if you have the List-Unsubscribe header set up, when someone clicks on the "Spam" button, it asks them whether they want to unsubscribe as well. If they say "yes", an email gets sent to the unsubscribe address with "Unsubscribe" as the subject.