My criticism of the standard is very simple:
The majority of already existing vault systems use:
withdraw(uint256 shares)
That’s because shares become the unit of measure for the vault once you have deposited.
This is used because:
- The token takes it’s own meaning and life (bBADGER, yveCRV)
- The user interface is simpler: “You are going to burn X shares and receive underlying back”
- The
_value
math is provenly more complicated, can break (especially if you add fees (e.g. withdrawal fees), and tends to leave dust. This is a known issue by all protocols that use the interface you are recommending.
To prove this I’ll just search for “Dust” on the Rari Capital Discord:
Practically this interface causes more issues than necessary, offer sub-par DX and UX and implicitly makes the majority of already existing Vault Systems non-compliant