mirror of
https://github.com/Smaug123/WoofWare.Whippet
synced 2025-10-05 07:48:40 +00:00
Add composition operators (#32)
Some checks are pending
.NET / Check links (push) Waiting to run
.NET / Check flake (push) Waiting to run
.NET / nuget-pack (push) Waiting to run
.NET / build (Debug) (push) Waiting to run
.NET / build (Release) (push) Waiting to run
.NET / analyzers (push) Waiting to run
.NET / check-dotnet-format (push) Waiting to run
.NET / check-nix-format (push) Waiting to run
.NET / expected-pack (push) Blocked by required conditions
.NET / check-accurate-generations (push) Waiting to run
.NET / all-required-checks-complete (push) Blocked by required conditions
.NET / nuget-publish (push) Blocked by required conditions
.NET / nuget-publish-core (push) Blocked by required conditions
.NET / nuget-publish-fantomas (push) Blocked by required conditions
.NET / nuget-publish-json-plugin (push) Blocked by required conditions
.NET / nuget-publish-json-attrs (push) Blocked by required conditions
.NET / nuget-publish-argparser-plugin (push) Blocked by required conditions
.NET / nuget-publish-argparser-attrs (push) Blocked by required conditions
.NET / nuget-publish-httpclient-plugin (push) Blocked by required conditions
.NET / nuget-publish-httpclient-attrs (push) Blocked by required conditions
.NET / nuget-publish-interfacemock-plugin (push) Blocked by required conditions
.NET / nuget-publish-interfacemock-attrs (push) Blocked by required conditions
.NET / nuget-publish-swagger-plugin (push) Blocked by required conditions
Some checks are pending
.NET / Check links (push) Waiting to run
.NET / Check flake (push) Waiting to run
.NET / nuget-pack (push) Waiting to run
.NET / build (Debug) (push) Waiting to run
.NET / build (Release) (push) Waiting to run
.NET / analyzers (push) Waiting to run
.NET / check-dotnet-format (push) Waiting to run
.NET / check-nix-format (push) Waiting to run
.NET / expected-pack (push) Blocked by required conditions
.NET / check-accurate-generations (push) Waiting to run
.NET / all-required-checks-complete (push) Blocked by required conditions
.NET / nuget-publish (push) Blocked by required conditions
.NET / nuget-publish-core (push) Blocked by required conditions
.NET / nuget-publish-fantomas (push) Blocked by required conditions
.NET / nuget-publish-json-plugin (push) Blocked by required conditions
.NET / nuget-publish-json-attrs (push) Blocked by required conditions
.NET / nuget-publish-argparser-plugin (push) Blocked by required conditions
.NET / nuget-publish-argparser-attrs (push) Blocked by required conditions
.NET / nuget-publish-httpclient-plugin (push) Blocked by required conditions
.NET / nuget-publish-httpclient-attrs (push) Blocked by required conditions
.NET / nuget-publish-interfacemock-plugin (push) Blocked by required conditions
.NET / nuget-publish-interfacemock-attrs (push) Blocked by required conditions
.NET / nuget-publish-swagger-plugin (push) Blocked by required conditions
This commit is contained in:
@@ -212,6 +212,7 @@ WoofWare.Whippet.Fantomas.SynExpr.callGenericMethod [static method]: Fantomas.FC
|
||||
WoofWare.Whippet.Fantomas.SynExpr.callGenericMethod' [static method]: string -> string -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.callMethod [static method]: string -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.callMethodArg [static method]: string -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.composeWith [static method]: Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.createCompExpr [static method]: string -> Fantomas.FCS.Syntax.SynExpr -> WoofWare.Whippet.Fantomas.CompExprBinding list -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.createDo [static method]: Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.createForEach [static method]: Fantomas.FCS.Syntax.SynPat -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
@@ -235,6 +236,7 @@ WoofWare.Whippet.Fantomas.SynExpr.greaterThan [static method]: Fantomas.FCS.Synt
|
||||
WoofWare.Whippet.Fantomas.SynExpr.greaterThanOrEqual [static method]: Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.ifThenElse [static method]: Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.index [static method]: Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.leftComposeWith [static method]: Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.lessThan [static method]: Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.lessThanOrEqual [static method]: Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
WoofWare.Whippet.Fantomas.SynExpr.listCons [static method]: Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr -> Fantomas.FCS.Syntax.SynExpr
|
||||
@@ -286,6 +288,8 @@ WoofWare.Whippet.Fantomas.SynIdent.createS [static method]: string -> Fantomas.F
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent inherit obj
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.booleanAnd [static property]: [read-only] Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.booleanOr [static property]: [read-only] Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.compose [static property]: [read-only] Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.composeLeft [static property]: [read-only] Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.create [static method]: Fantomas.FCS.Syntax.Ident list -> Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.createI [static method]: Fantomas.FCS.Syntax.Ident -> Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.createS [static method]: string -> Fantomas.FCS.Syntax.SynLongIdent
|
||||
@@ -294,6 +298,8 @@ WoofWare.Whippet.Fantomas.SynLongIdent.eq [static property]: [read-only] Fantoma
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.geq [static property]: [read-only] Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.get_booleanAnd [static method]: unit -> Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.get_booleanOr [static method]: unit -> Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.get_compose [static method]: unit -> Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.get_composeLeft [static method]: unit -> Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.get_eq [static method]: unit -> Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.get_geq [static method]: unit -> Fantomas.FCS.Syntax.SynLongIdent
|
||||
WoofWare.Whippet.Fantomas.SynLongIdent.get_gt [static method]: unit -> Fantomas.FCS.Syntax.SynLongIdent
|
||||
|
@@ -74,6 +74,14 @@ module SynExpr =
|
||||
let pipeThroughFunction (func : SynExpr) (expr : SynExpr) : SynExpr =
|
||||
createAppInfix (createLongIdent'' SynLongIdent.pipe) expr |> applyTo func
|
||||
|
||||
/// {expr} >> {func}
|
||||
let composeWith (func : SynExpr) (expr : SynExpr) : SynExpr =
|
||||
createAppInfix (createLongIdent'' SynLongIdent.compose) expr |> applyTo func
|
||||
|
||||
/// {expr} << {func}
|
||||
let leftComposeWith (func : SynExpr) (expr : SynExpr) : SynExpr =
|
||||
createAppInfix (createLongIdent'' SynLongIdent.composeLeft) expr |> applyTo func
|
||||
|
||||
/// if {cond} then {trueBranch} else {falseBranch}
|
||||
/// Note that this function puts the trueBranch last, for pipelining convenience:
|
||||
/// we assume that the `else` branch is more like an error case and is less interesting.
|
||||
|
@@ -61,6 +61,14 @@ module SynLongIdent =
|
||||
let pipe =
|
||||
SynLongIdent.SynLongIdent ([ Ident.create "op_PipeRight" ], [], [ Some (IdentTrivia.OriginalNotation "|>") ])
|
||||
|
||||
/// The ">>" identifier.
|
||||
let compose =
|
||||
SynLongIdent.SynLongIdent ([ Ident.create "op_ComposeRight" ], [], [ Some (IdentTrivia.OriginalNotation ">>") ])
|
||||
|
||||
/// The "<<" identifier.
|
||||
let composeLeft =
|
||||
SynLongIdent.SynLongIdent ([ Ident.create "op_ComposeLeft" ], [], [ Some (IdentTrivia.OriginalNotation "<<") ])
|
||||
|
||||
/// Convert this SynLongIdent into a human-readable string for display.
|
||||
/// This is not quite round-trippable, but it should be round-trippable if your identifiers are not pathological
|
||||
/// (e.g. you should not have a full stop in your identifiers; that's the job of LongIdent, not Ident).
|
||||
|
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"version": "0.5",
|
||||
"version": "0.6",
|
||||
"publicReleaseRefSpec": [
|
||||
"^refs/heads/main$"
|
||||
],
|
||||
|
Reference in New Issue
Block a user