Phoenix-Protocol-Group / phoenix-contracts

Source code of the smart contracts of the Phoenix DeFi hub DEX protocol
GNU General Public License v3.0
10 stars 6 forks source link

Pool: Implement `panic_with_error` macro #206

Closed ueco-jb closed 7 months ago

ueco-jb commented 7 months ago

Lately I've been seeing more and more errors of type UnreachableCodeReached (great error type by the way). I found on discord:

(...) more specifically panic!() automatic translates to the unreachable instruction when compiled

Now I'm trying to do a deployment with the panic_with_error, which supposed to at least return a error number...