Skip to content

fsharp/fslang-spec

Repository files navigation

F# Language Specification

Overview

This is an initiative to create a more complete and community-maintainable F# spec.

This will be no small task, but we believe it is worthwhile and we count on community contributions.

We foresee three phases:

  1. Convert the latest official spec to markdown and create the structure and tools to make it community-maintainable. This is done.
  2. Add the post-4.1 features as documented in the RFCs to the spec. Our goal: a complete F# 10 spec.
  3. Make spec update part of new feature development so that an up-to-date spec can be released with every new major compiler release.

Process

The spec is in the end closely coupled to the language design and therefore needs a) strong community contributions and b) a clearly defined final responsibility, which will be similar to the one of the language design process.

We foresee the following types of contributions:

  • Issues and/or PRs for bug fixes.
  • PRs for integration of an accepted and implemented RFC.
  • Issues for proposing and discussing smaller or larger improvements to the spec
  • PRs for such improvements, once the discussion converges and/or is decided by the team in charge

All PRs need to be accepted by two team reviewers for merging.

Repository structure

The sources are the markdown files for the chapters (clauses) in the spec directory. Run build to create a new complete spec (including ToC and updated reference links) in your artifacts directory.

At certain points, releases are created and published in the releases directory.

F# Language Features RFCs

Version Feature ID Feature with RFC Link Status
F# 4.0 N/A Auto Quotation This was already covered (see § 8.13.7.3 and the FSharp.Core documentation)
F# 4.0 N/A Class Names As Functions done
F# 4.0 N/A Core Library Functions This was replaced by the RFC "List, Seq, Array Additions", see below
F# 4.0 N/A Extended If Grammar This was already covered (see §3.3)
F# 4.0 N/A Extension Property Initializers This was already covered (see §14.4, item 4, 5th bullet, second sub-bullet, second sentence)
F# 4.0 N/A List, Seq, Array Additions This is documented in the FSharp.Core documentation. FSharp.Core functionality is not documented in detail in this spec, except as needed for reference (see §18)
F# 4.0 N/A Microsoft Optional Both library documentation and spec were adapted already.
F# 4.0 N/A Multi-Interface Instantiation
F# 4.0 N/A Non-Null Provided Types
F# 4.0 N/A Printf Units of Measure
F# 4.0 N/A Static Method Arguments
F# 4.1 FS-1002 Cartesian Product for Collections
F# 4.1 FS-1004 Result Type done
F# 4.1 FS-1005 Underscores in Numeric Literals done
F# 4.1 FS-1006 Struct Tuples done
F# 4.1 FS-1007 Additional Option Module Functions
F# 4.1 FS-1008 Struct Records
F# 4.1 FS-1009 Mutually Referential Types and Modules in Single Scope
F# 4.1 FS-1010 Add Map.count
F# 4.1 FS-1012 Caller Info Attributes
F# 4.1 FS-1013 Enable Reflection Functionality on Portable Profiles
F# 4.1 FS-1014 Struct Discriminated Unions
F# 4.1 FS-1015 Support for fixed
F# 4.1 FS-1016 Unreserve Keywords
F# 4.1 FS-1017 Fix SRTP Constraint Parsing
F# 4.1 FS-1018 Adjust Extensions Method Scope
F# 4.1 FS-1019 Implicitly Add the Module Suffix
F# 4.1 FS-1020 ByRef Returns
F# 4.1 FS-1025 Improve Record Type Inference
F# 4.1 FS-1027 Complete Optional DefaultParameterValue
F# 4.1 FS-1029 Implement IReadOnlyCollection in list
F# 4.1 FS-1040 Enum Match
F# 4.5 FS-1047 Match Bang
F# 4.5 FS-1053 Span
F# 4.5 FS-1054 Undent List Args
F# 4.5 FS-1055 Subsumption for Yield in Sequence Expression
F# 4.5 FS-1058 Make Enum Cases Public
F# 4.6 FS-1030 Anonymous Records
F# 4.7 FS-1046 Wildcard Self Identifiers
F# 4.7 FS-1069 Implicit Yields
F# 4.7 FS-1070 Offside Relaxations
F# 5.0 FS-1001 String Interpolation
F# 5.0 FS-1003 Nameof Operator
F# 5.0 FS-1031 Allow Implementing Same Interface at Different Generic Instantiations
F# 5.0 FS-1063 Support LetBang and AndBang for Applicative Functors
F# 5.0 FS-1068 Open Type Declaration
F# 5.0 FS-1071 Witness Passing Quotations
F# 5.0 FS-1074 Default Interface Member Consumption
F# 5.0 FS-1075 Nullable Interop
F# 5.0 FS-1077 3D/4D Fixed Index Slicing
F# 5.0 FS-1077 Tolerant Slicing
F# 5.0 FS-1080 Float32 Without Dot
F# 5.0 FS-1082 Uint Type Abbreviation
F# 5.0 FS-1085 Nameof Pattern
F# 5.0 FS-1089 Allow String Everywhere
F# 6.0 FS-1039 Struct Representation for Active Patterns
F# 6.0 FS-1056 Allow Custom Operation Overloads
F# 6.0 FS-1087 Resumable Code
F# 6.0 FS-1091 Extend Units of Measure done
F# 6.0 FS-1093 Additional Conversions
F# 6.0 FS-1097 Task Builder
F# 6.0 FS-1098 Inline If Lambda
F# 6.0 FS-1099 List Collector
F# 6.0 FS-1100 Printf Binary
F# 6.0 FS-1102 Discards on Use Bindings
F# 6.0 FS-1104 Struct Representations
F# 6.0 FS-1105 Non-variable Patterns to the Right of As Patterns
F# 6.0 FS-1107 Allow Attributes After the Module Keyword
F# 6.0 FS-1108 Undentation Frenzy
F# 6.0 FS-1109 Additional Intrinsics for the NativePtr Module
F# 6.0 FS-1110 Index Syntax
F# 6.0 FS-1111 RefCell Op Information Messages
F# 6.0 FS-1113 Insert Remove Update Functions
F# 6.0 FS-1114 ML Compat Revisions
F# 7.0 FS-1024 Simplify Constrained Call Syntax
F# 7.0 FS-1083 SRTP Type No Whitespace
F# 7.0 FS-1096 Map Min Max KeyValue
F# 7.0 FS-1123 Result Module Parity with Option
F# 7.0 FS-1124 Interfaces with Static Abstract Members
F# 7.0 FS-1126 Allow Lower Case DU Cases when RequireQualifiedAccess is Specified
F# 7.0 FS-1127 Init Only and Required Properties
F# 7.0 FS-1131 NoCompilerInliningAttribute
F# 7.0 FS-1133 Arithmetic in Literals
F# 8.0 FS-1011 Warn on Recursive Without Tail Call
F# 8.0 FS-1081 Extended Fixed Bindings
F# 8.0 FS-1128 Allow Static Members in Interfaces
F# 8.0 FS-1129 Shorthand Anonymous Unary Functions
F# 8.0 FS-1132 Better Interpolated Triple Quoted Strings
F# 8.0 FS-1134 Try With in Sequence Expressions
F# 8.0 FS-1136 Constraint Intersection Syntax
F# 9.0 FS-1060 Nullable Reference Types
F# 9.0 FS-1079 Union Properties Visible
F# 9.0 FS-1140 Boolean Returning and Return Type Directed Partial Active Patterns
F# 9.0 FS-1144 Empty Bodied Computation Expressions
F# 9.0 FS-1147 Non-String Directive Args

FSharp.Core RFCs

Version Feature ID Feature with RFC Link Status
FSharp.Core 4.4.3.0 FS-1028 Implement Async.StartImmediateAsTask
FSharp.Core 4.4.3.0 FS-1036 Consistent Slicing
FSharp.Core 4.4.3.0 FS-1041 IReadOnly
FSharp.Core 4.4.3.0 FS-1042 Add Seq.transpose
FSharp.Core 4.4.3.0 FS-1044 Add NativePtr.toByRef
FSharp.Core 4.5.0.0 FS-1045 Func to FSharpFunc Overloads
FSharp.Core 4.5.0.0 FS-1050 TryGetValue Map
FSharp.Core 4.5.0.0 FS-1057 ValueOption
FSharp.Core 4.5.0.0 FS-1059 Improve Async Stack Traces
FSharp.Core 4.6.0 FS-1065 ValueOption Parity
FSharp.Core 4.6.0 FS-1066 tryExactlyOne
FSharp.Core 4.7.0 FS-1067 Async Sequential
FSharp.Core 8.0 FS-1130 Array Parallel Collection Functions More Regular
FSharp.Core 9.0 FS-1135 Random Functions for Collections
FSharp.Core 9.0 FS-1145 C# Collection Expression Support for Lists and Sets

About

F# Language Specification

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 9

Languages