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

Make OrderBook covariant in its Order type parameter #222

Closed
davidrpugh opened this issue Oct 25, 2016 · 1 comment
Closed

Make OrderBook covariant in its Order type parameter #222

davidrpugh opened this issue Oct 25, 2016 · 1 comment

Comments

@davidrpugh
Copy link
Contributor

Logically, since AskOrder <: Order then it should follow that OrderBook[AskOrder] <: OrderBook[Order] however this is currently not the case in the code. Will need to refactor the add and reduce method signatures to make this possible.

@davidrpugh
Copy link
Contributor Author

I am closing this issue because I am no longer convinced that OrderBook should be covariant in type parameter...possibly should be contravariant!

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

No branches or pull requests

1 participant