In general, no. Unless you do it with fraudulent intent:
Title 18 United States Code, Section 331
Whoever fraudulently alters, defaces, mutilates, impairs, diminishes, falsifies, scales, or lightens any of the coins coined at the mints of the United States, or any foreign coins which are by law made current or are in actual use or circulation as money within the United States;
or
Whoever fraudulently possesses, passes, utters, publishes, or sells, or attempts to pass, utter, publish, or sell, or brings into the United States, any such coin, knowing the same to be altered, defaced, mutilated, impaired, diminished, falsified, scaled, or lightened -
Shall be fined under this title or imprisoned not more than five years, or both.
For an interesting explanation of why it is now illegal to melt pennies and nickels see:
I wonder if you can do this legally outside the US. I'm sure there's plenty of tourists with bags of US change that they can't easily take to the bank. Seems like it might be a loophole worth exploiting.