Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement getPair() and allPairs() functions #114

Open
gluneau opened this issue Jul 19, 2022 · 5 comments
Open

Implement getPair() and allPairs() functions #114

gluneau opened this issue Jul 19, 2022 · 5 comments
Assignees

Comments

@gluneau
Copy link

gluneau commented Jul 19, 2022

A request to Implement getPair(address tokenA, address tokenB) and allPairs(uint) functions came from the Orion Team

@gluneau gluneau changed the title Implement getPair(address tokenA, address tokenB) and allPairs(uint) Implement getPair() and allPairs() functions Jul 19, 2022
@zjb0807
Copy link
Member

zjb0807 commented Jul 20, 2022

I think we have the getPair

/**
* @dev Get Liquidity token address.
* Returns (liquidity_token_address). Return address(0x0) if the liquidity token address is not mapped.
*/
function getLiquidityTokenAddress(address tokenA, address tokenB)

@gluneau
Copy link
Author

gluneau commented Jul 21, 2022

@gluneau
Copy link
Author

gluneau commented Jul 21, 2022

@ferrell-code
Copy link
Contributor

Also, I think allPairs() is not possible to do identically to uniswap because we don't have an index (0-n) mapped to pairs enabled

@xlc
Copy link
Member

xlc commented Jul 25, 2022

We need a precompile to iterate enabled pairs and return them.
However, not 100% sure why do we need such method?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants