Skip to content

Change the namespace of the public "InferenceMode" enum#1470

Merged
cartermp merged 2 commits intofsprojects:mainfrom
mlaily:fix-inferencemode-ns
Jan 7, 2023
Merged

Change the namespace of the public "InferenceMode" enum#1470
cartermp merged 2 commits intofsprojects:mainfrom
mlaily:fix-inferencemode-ns

Conversation

@mlaily
Copy link
Copy Markdown
Contributor

@mlaily mlaily commented Jan 6, 2023

This is a breaking change, but I feel like it's needed...

Using FSharp.Data.Runtime.StructuralInference was a mistake (sorry, my bad). It should not be necessary to reference that namespace just to initialize a type provider...

I moved the enum to the FSharp.Data namespace instead, the same as the providers so it's readily available:

  • Nothing has to be explicitly opened to use the enum with a type provider.
  • This will hopefully make the breaking change less painful since it is likely to still compile after the update.

I have no idea how much this new-ish enum is used in the wild, but since it's optional and a bit obscure, it might not impact too many users...

Since the next version will be the new major version 6.x and it's still currently in beta, I think this is a good opportunity to do this kind of thing now.

mlaily added 2 commits January 6, 2023 21:54
FSharp.Data.Runtime.StructuralInference should not have to be
opened by end users just to initialize a type provider...
@mlaily mlaily force-pushed the fix-inferencemode-ns branch from c9d9df1 to ab2562a Compare January 6, 2023 21:54
Copy link
Copy Markdown
Collaborator

@cartermp cartermp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Definitely fine with the change here.

@cartermp cartermp merged commit dae3089 into fsprojects:main Jan 7, 2023
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

Successfully merging this pull request may close these issues.

2 participants