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

Question: fable compatible? #3

Open
OnurGumus opened this issue Jul 25, 2022 · 4 comments
Open

Question: fable compatible? #3

OnurGumus opened this issue Jul 25, 2022 · 4 comments

Comments

@OnurGumus
Copy link

Is this at least partially fable compatible?

@farlee2121
Copy link
Owner

farlee2121 commented Jul 25, 2022

Hmm. I haven't tried using it with fable yet. Looking at the compatability guide. I would guess it is not very compatible because

It's not possible to type test against interfaces or generic types.

The core FsSpec library only depends on Fsharp.Core and a few basic types from the BCL (IComparable<T>, IEnumerable, EqualityComparer<T>). The problem comes from the use of type tests and reflection to check implementation of those interfaces.

@farlee2121
Copy link
Owner

Hmm, actually most of the type testing is in the data generation library.
I think validation (thus explanation and formatting) might work for all the constraints except length.
We might be able to change the implementation of length validation to accommodate Fable too

@OnurGumus
Copy link
Author

Yes tests don't have to be fable compatible.

@farlee2121
Copy link
Owner

Not tests as in automated tests but type tests as in this example

| :? System.Collections.IEnumerable as coll ->

These are part of the production code and are not supported by fable

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

2 participants