You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I know these are always non-negative in Solidity, but it's kind of local to maker.py if we allow them to be negative. For example some arbitrage profitability calculations are performed in Wad and it's perfectly fine for profitability to be negative.
So the question is whether we want to keep Ray and Wad 100% compatible with Solidity types (in terms of sign, overflow etc.) and in that case we need another set of types for things like the aforementioned profitability calculation. Or do we relax these restrictions in the Python code (as it is currently done now).
I would keep Ray and Wad totally compatible and introduce signed versions that are int256 instead of uint128. Require explicit cast before it goes to the evm.
I have used them to hold negative values during calculations in a few places.
This issue is to figure out whether it should stay like that or not.
The text was updated successfully, but these errors were encountered: