Submitted by broccoli, also found by 0xsanson, cmichel, and WatchPug
When an Index pool is initiated with two tokens A: B and the weight rate = 1:2, then no user can buy token A with token B.
The root cause is the error in pow. It seems like the dev tries to implement Exponentiation by squaring.
IndexPool.sol#L286-L291
Theres no bracket for for.
The IndexPool is not functional. I consider this is a high-risk issue.
When we initiated the pool with 2:1.
No one can buy dai with link.
The brackets of for were missed.
