FSharp.Core.Extended
FSharp.Core.Extended copied to clipboard
A drop-in replacement for F# core library with generally faster defaults
What
[!WARNING] This library is very much work in progress, expect issues.
This library tries to be a drop-in replacement for the FSharp.Core with functions, which are generally faster and more flexible than built-in ones, but may be backwards-incompatible at runtime/compile-time.
Examples of current (and future planned) backwards-incompatibilities:
- Some collections functions (
min,max,sum, etc) can handle things likeNaNdifferently thanFSharp.Core. - All
try*functions returnValueOption<'T>. Option<'T>is aliasingValueOption<'T>, allOptionmodule functions shadowing the ones fromFSharp.Core, several helper functions/methods provided to convert back and from theFSharp.Core.Option<'T>....
How to use:
This library being a drop-in replacement doesn't mean that just referencing its NuGet package is enough. Shadowing is achieved by opening this library's namespace (works on any granularity), for example:
open FSharp.Core.Extended
will shadow every module and type defined in this library (e.g. Option type, Option module, Array module, List module, etc)
open FSharp.Core.Extended.Collections
will shadow every module and type defined for collections
open FSharp.Core.Extended.Collections.Array
will shadow every type and module defined for arrays
And so on.