Document limitation of delete for EnumerableSet and Map #3400
Labels
documentation
Inline comments, guides, and examples.
good first issue
Low hanging fruit for new contributors to get involved!
Solidity currently allows executing the
delete
operator on structs likeEnumerableSet
andEnumerableMap
even though they contain a mapping that will not be cleared, and the operation will in fact corrupt the struct's data.According to ethereum/solidity#11843 this operation will no longer be allowed in Solidity 0.9, but in the meantime we should document that
delete
should not be used with these types.The text was updated successfully, but these errors were encountered: