>Or a currency conversion machine where you can shove USDs in the slot to get EURs, but if you shove EURs in, to the shredder they go,
Very good explanation, thanks, though the machine you describe would not probably be called a "smart" ATM.
This example is kinda funny. If your bank notes were accidentally damaged in germany, you could send them to the federal bank and have them replaced as long as more than half of the bank note can be reconstructed. This is a service intended especially for victims of fire or flood catastrophes, though dog related accidents aren't unheard of either.
Why would you ever want to “shred the check”? Is this the intended functionality or a bug?
You don't, and it's not what technically happens, but it's the closest I could find as the actual behaviour can not be replicated in the real world.
The actual behaviour, at least in my understanding, is that the bank check goes in a box to which only the ATM has access, but the ATM was never coded to look for bank checks in the box, and it's not possible to update it, so it's not possible to get the bank checks out of the box.
In the real world you could take the box out and force it open, but in "the blockchain" the contract has sole control of the wallet, an updated version of the contract would be a different contract with a different address.
> Is this the intended functionality or a bug?
It is, in the broadest sense, a bug: the contract was not coded to handle anything other than ETH inputs, so it ignores everything else, but the other things were still moved into the box.
* there's a smart contract to which you can send ETH (directly), it sends WETH back
* however the inverse operation (WETH -> ETH) is not done by sending the WETH, you're supposed to call a special conversion function of the contract
I guess the smart contract only looks for ETH in its wallet (at its address), it ignores the WETH entirely, and thus the WETH become inaccessible.
So the contract is a deposit ATM where you can deposit cash and it spits out a bank check, but if you deposit a bank check it just shreds the check.
Or a currency conversion machine where you can shove USDs in the slot to get EURs, but if you shove EURs in, to the shredder they go,