Closed Wasram closed 6 years ago
I initially thought that using require() for those purposes was the best idea simply because of a gas refund. Following up with your post, I see that REVERT also undoes any state changes caused in the function which isn't desired here. Thanks for the direction!
On Tue, Mar 20, 2018 at 10:15 AM Maurelian notifications@github.com wrote:
require(false) will REVERT, which is not the same thing as RETURN false.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/ConsenSys/Tokens/pull/121#issuecomment-374635643, or mute the thread https://github.com/notifications/unsubscribe-auth/Ad-I-tPgaukNCm3TN7QhxWh2gXkZ1tamks5tgR0SgaJpZM4SvB5K .
require(false)
willREVERT
, which is not the same thing asRETURN
false.https://ethereum.stackexchange.com/questions/15166/difference-between-require-and-assert-and-the-difference-between-revert-and-thro/24185#24185