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

Add O (operator) modules to all numerical modules #113

Open
jasone opened this issue Mar 4, 2021 · 0 comments
Open

Add O (operator) modules to all numerical modules #113

jasone opened this issue Mar 4, 2021 · 0 comments

Comments

@jasone
Copy link
Contributor

jasone commented Mar 4, 2021

The Real module has Real.O, which makes local opens a convenient way of performing floating point operations without risk of namespace clashes. For example, let min = 3. in Real.O(min + 4.) doesn't trip on Real.min (contrived, but shows the brittleness of Real.(...)). This same problem can occur with any numerical type for which we might use a local open in order to access an infix operator. Therefore we should universally provide .O submodules for numerical modules.

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