Can you prevent a `revert` from happening?

I was wondering if there is a way to avoid the revert statement in this code example. Or to put it another way, could you write a smart contract that allows arbitrary operations as long as you have a revert all changes at the end of the function.

First, I thought you could call selfdestruct, but that would have an effect after the call and would be undone by revert, right?

  contract Reverter {       function callAndRevert(address externalAddress, bytes  calldata data) public {                  // do whatever   ;             address(this).delegatecall(data);              // revert             revert ("Dont care I revert");                      } }  

Can you prevent a `revert` from happening?

Shopping cart
There are no products in the cart!
Continue shopping