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

Some FSharpWrapper operators conflict with built-in F# operators #90

Open
nightroman opened this issue Nov 27, 2018 · 0 comments
Open

Comments

@nightroman
Copy link

nightroman commented Nov 27, 2018

Operators >> and << defined in src\FSharpWrapper\FSharpWrapper.fs
conflict with built-in F# function composition operators.

Example. The following code:

open Microsoft.ML.Probabilistic.FSharp

let f2 x = x * 2
let f3 x = x * 3
let f6 = f2 >> f3

results in the compiler error:

error FS0001: Expecting a type supporting the operator '>' but given a function
type. You may be missing an argument to a function.

If we comment out open Microsoft.ML.Probabilistic.FSharp then it compiles.
But then it is harder to work with F# wrapper features, especially operators.

If the choice of operators was not an intentional design decision with
awareness of the conflicts, can these operators be changed?

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

1 participant