Only if it actually stopped people buying things advertised in spam emails. That would probably need there to be a credible risk of getting caught when buying something advertised in a spam email. That seems awfully difficult: how are the police -- or whoever -- going to know you're buying something from a spammer? how could they prove it? why would they bother, given all the other crimes they could be going after?
Now, maaaybe making it illegal to by Hrebal Vigara would dissuade potential customers despite the negligible chance that they'd get into any trouble for it. But do you really think it would dissuade them enough to make much difference to the profitability of the spam? Doesn't seem at all likely to me.