| id | stdlib-reference |
|---|---|
| title | Standard Library Signature Index |
| slug | /reference/stdlib |
This is the complete catalog of core functions/values and default .NET runtime externs. Each name links to argument order, examples, and failure behavior. Type variables are local to each signature; repeated variables in a row must agree.
Core functions are always available. Runtime functions require host registration, are enabled by default in the CLI, and are disabled by --no-default-externs or runtime.default-externs = false. JavaScript hosts provide their own externs. Registered custom providers add functions beyond this standard catalog.
| Name | Type | Availability |
|---|---|---|
ignore |
'a -> unit |
Core function; evaluates and discards its argument |
Env |
Environment |
Value injected by CLI/REPL, optional in embedding hosts |
Environment |
{ ScriptName: string option; Arguments: string list } |
Built-in record type |
FsKind |
File of string / Directory of string / Missing |
Built-in union type |
| Name | Signature |
|---|---|
Bool.toString |
bool -> string |
Bool.tryParse |
string -> bool option |
| Name | Signature |
|---|---|
Float.toString |
float -> string |
Float.tryParse |
string -> float option |
| Name | Signature |
|---|---|
Int.toString |
int -> string |
Int.tryParse |
string -> int option |
| Name | Signature |
|---|---|
List.append |
'a list -> 'a list -> 'a list |
List.choose |
('a -> 'b option) -> 'a list -> 'b list |
List.collect |
('a -> 'b list) -> 'a list -> 'b list |
List.contains |
'a -> 'a list -> bool |
List.distinct |
'a list -> 'a list |
List.empty |
'a list |
List.exists |
('a -> bool) -> 'a list -> bool |
List.filter |
('a -> bool) -> 'a list -> 'a list |
List.fold |
('b -> 'a -> 'b) -> 'b -> 'a list -> 'b |
List.iter |
('a -> unit) -> 'a list -> unit |
List.length |
'a list -> int |
List.map |
('a -> 'b) -> 'a list -> 'b list |
List.rev |
'a list -> 'a list |
List.tail |
'a list -> 'a list |
List.tryFind |
('a -> bool) -> 'a list -> 'a option |
List.tryGet |
('a -> bool) -> 'a list -> int option |
List.tryHead |
'a list -> 'a option |
List.tryItem |
int -> 'a list -> 'a option |
| Name | Signature |
|---|---|
Map.add |
'b -> 'a -> 'a map['b] -> 'a map['b] |
Map.choose |
('b -> 'a -> 'c option) -> 'a map['b] -> 'c map['b] |
Map.containsKey |
'b -> 'a map['b] -> bool |
Map.count |
'a map['b] -> int |
Map.empty |
'a map['b] |
Map.filter |
('b -> 'a -> bool) -> 'a map['b] -> 'a map['b] |
Map.fold |
('c -> 'b -> 'a -> 'c) -> 'c -> 'a map['b] -> 'c |
Map.iter |
('b -> 'a -> unit) -> 'a map['b] -> unit |
Map.map |
('a -> 'c) -> 'a map['b] -> 'c map['b] |
Map.ofList |
('b * 'a) list -> 'a map['b] |
Map.remove |
'b -> 'a map['b] -> 'a map['b] |
Map.tryGet |
'b -> 'a map['b] -> 'a option |
| Name | Signature |
|---|---|
Option.defaultValue |
'a -> 'a option -> 'a |
Option.defaultWith |
(unit -> 'a) -> 'a option -> 'a |
Option.isNone |
'a option -> bool |
Option.isSome |
'a option -> bool |
Option.map |
('a -> 'b) -> 'a option -> 'b option |
| Name | Signature |
|---|---|
String.concat |
string -> string list -> string |
String.endsWith |
string -> string -> bool |
String.indexOf |
string -> string -> int option |
String.replace |
string -> string -> string -> string |
String.split |
string -> string -> string list |
String.substring |
int -> int -> string -> string option |
String.toLower |
string -> string |
String.toUpper |
string -> string |
| Name | Signature |
|---|---|
Console.readLine |
unit -> string option |
Console.writeLine |
string -> unit |
| Name | Signature |
|---|---|
Fs.combinePath |
string -> string -> string |
Fs.createDirectory |
string -> bool |
Fs.enumerateFiles |
string -> string -> string list option |
Fs.exists |
string -> bool |
Fs.extension |
string -> string option |
Fs.fileNameWithoutExtension |
string -> string |
Fs.glob |
string -> string list option |
Fs.kind |
string -> FsKind |
Fs.parentDirectory |
string -> string option |
Fs.readText |
string -> string option |
Fs.writeText |
string -> string -> bool |
| Name | Signature |
|---|---|
Guid.new |
'a -> string option |
| Name | Signature |
|---|---|
Hash.md5 |
string -> string option |
| Name | Signature |
|---|---|
Json.deserialize |
type -> string -> 'a option |
Json.serialize |
'a -> string option |
| Name | Signature |
|---|---|
Regex.matchGroups |
string -> string -> string list option |
| Name | Signature |
|---|---|
Task.await |
'a task -> 'a |
Task.spawn |
(unit -> 'a) -> 'a task |
| Name | Signature |
|---|---|
Xml.queryValues |
string -> string -> string list option |
Constructors and syntax are separate from function registration: Some/None, union cases, literals, ranges, field access, list/map indexers, typeof, and nameof are covered in Native Types and Syntax and Operators. Host-provided type descriptors are covered in Host-Provided Types.
Json.deserialize uses a runtime type token; its generic result scheme does not statically encode the relationship between that token and the result. Guid.new accepts an ignored argument; use Guid.new (). List.contains compares scalars only; use List.exists with = for composite data.