{"id":13508185,"url":"https://github.com/tc39/proposal-partial-application","last_synced_at":"2025-10-06T02:52:18.222Z","repository":{"id":22910814,"uuid":"97652594","full_name":"tc39/proposal-partial-application","owner":"tc39","description":"Proposal to add partial application to ECMAScript","archived":false,"fork":false,"pushed_at":"2022-05-22T16:32:16.000Z","size":318,"stargazers_count":1027,"open_issues_count":9,"forks_count":25,"subscribers_count":95,"default_branch":"main","last_synced_at":"2025-05-24T00:07:14.968Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://tc39.es/proposal-partial-application/","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tc39.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-07-18T23:33:55.000Z","updated_at":"2025-05-05T20:39:18.000Z","dependencies_parsed_at":"2022-09-02T13:21:33.976Z","dependency_job_id":null,"html_url":"https://github.com/tc39/proposal-partial-application","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/tc39/proposal-partial-application","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tc39%2Fproposal-partial-application","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tc39%2Fproposal-partial-application/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tc39%2Fproposal-partial-application/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tc39%2Fproposal-partial-application/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tc39","download_url":"https://codeload.github.com/tc39/proposal-partial-application/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tc39%2Fproposal-partial-application/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278551493,"owners_count":26005388,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-06T02:00:05.630Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-01T02:00:49.380Z","updated_at":"2025-10-06T02:52:18.201Z","avatar_url":"https://github.com/tc39.png","language":"HTML","readme":"# Partial Application Syntax for ECMAScript\n\nThis proposal introduces syntax for a new calling convention (using `~()`) to allow you to\npartially apply an argument list to a call or `new` expression through the combination of\n_applied arguments_ (actual values) and _placeholder arguments_ (unbound arguments that\nbecome parameters in the resulting _partially applied function_).\n\n## Status\n\n**Stage:** 1  \n**Champion:** Ron Buckton (@rbuckton)\n\n_For more information see the [TC39 proposal process](https://tc39.github.io/process-document/)._\n\n## Authors\n\n* Ron Buckton (@rbuckton)\n\n# Proposal\n\nPartial function application allows you to fix a number of arguments to a function call, returning\na new function. Partial application is supported after a fashion in ECMAScript today through the \nuse of either `Function.prototype.bind` or arrow functions:\n\n```js\nfunction add(x, y) { return x + y; }\n\n// Function.prototype.bind\nconst addOne = add.bind(null, 1);\naddOne(2); // 3\n\n// arrow functions\nconst addTen = x =\u003e add(x, 10);\naddTen(2); // 12\n```\n\nHowever, there are several of limitations with these approaches:\n\n* `Function.prototype.bind` can only fix the leading arguments of a function.\n* `Function.prototype.bind` requires you explicitly specify the `this` receiver.\n* Arrow functions lazily re-evaluate their bodies, which can introduce unintended side-effects.\n\nTo resolve these concerns, we propose the introduction of the following new language features:\n\n- A new calling convention, `~()`, to indicate a _partial application_ of a call or `new` expression which\n  results in a _partially applied function_.\n- Using the `?` token to act as a _placeholder argument_ for any non-fixed argument in a _partial application_.\n- Using the `?` token followed by a decimal integer literal (i.e., `?0`) to act as an _ordinal\n  placeholder argument_ for non-fixed arguments bound to a specific ordinal parameter in the resulting _partially\n  applied function_.\n- Using the `...` token to act as a _rest placeholder argument_ for any excess arguments.\n\n```js\nconst add = (x, y) =\u003e x + y;\nconst identity = x =\u003e x;\n\n// apply from the left:\nconst addOne = add~(1, ?);\naddOne(2); // 3\n\n// apply from the right:\nconst addTen = add~(?, 10);\naddTen(2); // 12\n\n// accept a fixed argument list:\nconst numbers = [\"1\", \"2\", \"3\"].map(parseInt~(?, 10)); // [1, 2, 3]\n\n// specify ordinal placeholder arguments:\nconst indices = [1, 2, 3].map(identity~(?1)); // [0, 1, 2]\n\n// bind `console` as receiver and accepts exactly one argument:\n[1, 2, 3].forEach(console.log~(?));\n// prints:\n// 1\n// 2\n// 3\n\n// emulate n-ary arguments like Function.prototype.bind:\nconst logger = console.log~(\"[service]\", ...);\nlogger(\"foo\", \"bar\"); // prints: [service] foo bar\n```\n\n# Syntax\n\n## The `~()` Partial Application Calling Convention\n\nA partially applied call uses a separate calling convention than a normal call. Instead of using `()`\nto call or construct a value, you initiate a partial call using `~()`. A partially applied call without\na placeholder argument essentially fixes any provided arguments into a new function. If the expression being\ninvoked produces a _Reference_, the `this` binding of the _Reference_ is preserved. Excess arguments supplied \nto the resulting function are ignored by default (for more information, see [Fixed Arity](#fixed-arity) and\n[Variable Arity](#variable-arity-pass-through-remaining-arguments-using-) later on in this document).\n\n```js\nconst sayNothing = console.log~();\nconst sayHi = console.log~(\"Hello!\");\n\nsayNothing();       // prints:\nsayNothing(\"Shhh\"); // prints:\n\nsayHi();            // prints: Hello!\n\nconst bob = {\n  name: \"Bob\",\n  introduce() {\n    console.log(`Hello, my name is ${this.name}.`);\n  }\n};\n\nconst introduceBob = bob.introduce~();\nintroduceBob();     // prints: Hello, my name is Bob.\n```\n\nThis would not be the first new calling convention in ECMAScript, which also has tagged templates (i.e., `` tag`text${expr}` ``)\nand nullish function evaluation (i.e., `f?.()`).\n\n## The `?` Placeholder Argument\n\nThe `?` _Placeholder Argument_ can be supplied one or more times at the top level of the argument list of\na call or `new` expression (e.g. `f~(?)` or `o.f~(?)`). `?` is **not** an expression, rather it is a\nsyntactic element that indicates special behavior (much like how `` `...` AssignmentExpression `` indicates\nspread, yet is itself not an expression).\n\n```js\n// valid\nf~(x, ?)          // partial application from left\nf~(?, x)          // partial application from right\nf~(?, x, ?)       // partial application for any arg\no.f~(x, ?)        // partial application from left\no.f~(?, x)        // partial application from right\no.f~(?, x, ?)     // partial application for any arg\nsuper.f~(?)       // partial application allowed for call on |SuperProperty|\nnew C~(?)         // partial application of constructor\n\n// invalid\nf~(x + ?)         // `?` not in top-level Arguments of call\nx + ?             // `?` not in top-level Arguments of call\n?.f~()            // `?` not in top-level Arguments of call\nsuper~(?)         // `?` not supported in |SuperCall|\nimport~(?)        // `?` not supported in |ImportCall|\n```\n\n## The `?0` (`?1`, `?2`, etc.) Ordinal Placeholder Argument\n\nThe `?` token can be followed by a decimal integer value \u0026ge; 0 indicating a fixed ordinal position (i.e., `?0`)\ndenoting an _Ordinal Placeholder Argument_. Ordinal placeholder arguments are especially useful for adapting\nexisting functions to be used as callbacks to other functions expect arguments in a different order:\n\n```js\nconst printAB = (a, b) =\u003e console.log(`${a}, ${b}`);\nconst acceptBA = (cb) =\u003e cb(\"b\", \"a\");\nacceptBA(printAB~(?1, ?0));                // prints: a, b\n```\n\nIn addition, ordinal placeholder arguments can be repeated multiple times within a partial application,\nallowing repeated references to the same argument value:\n\n```js\nconst add = (x, y) =\u003e x + y;\nconst dup = add(?0, ?0);\nconsole.log(dup(3));                       // prints: 6\n```\n\nNon-ordinal placeholder arguments are implicitly ordered sequentially from left to right. This means that an\nexpression like `f~(?, ?)` is essentially equivalent to `f~(?0, ?1)`. If a partial application contains a mix\nof ordinal placeholder arguments and non-ordinal placeholder arguments, ordinal placeholder arguments\ndo not affect the implicit order assigned to non-ordinal placeholder arguments:\n\n```js\nconst printABC = (a = \"arg0\", b = \"arg1\", c = \"arg2\") =\u003e console.log(`${a}, ${b}, ${c}`);\nprintABC(1, 2, 3);                         // prints: 1, 2, 3\nprintABC();                                // prints: arg0, arg1, arg2\n\nconst printCAA = printABC~(?2, ?, ?0);     // equivalent to: printABC~(?2, ?0, ?0)\nprintCAA(1, 2, 3);                         // prints: 3, 1, 1\nprintCAA(1, 2);                            // prints: arg0, 1, 1\n\nconst printCxx = printABC~(?2);\nprintCxx(1, 2, 3);                         // prints: 3, arg1, arg2\n```\n\nBy having ordinal placeholder arguments independent of the ordering for non-ordinal placeholder arguments, we\navoid refactoring hazards due to the insertion a new ordinal placeholder into an existing partial application.\n\n_inserting an ordinal placeholder as the first argument:_\n```patch\n-  const g = f~(?, ?, ?);                   // equivalent to: f~(?0, ?1, ?2)\n+  const g = f~(?2, ?, ?, ?);               // equivalent to: f~(?2, ?0, ?1, ?2)\n```\n\n_inserting an ordinal placeholder between other placeholders:_\n```patch\n-  const g = f~(?, ?, ?);                   // equivalent to: f~(?0, ?1, ?2)\n+  const g = f~(?, ?, ?0, ?);               // equivalent to: f~(?0, ?1, ?0, ?2)\n```\n\n## Fixed Arity\n\nBy default, partial application uses a fixed argument list: Normal arguments are evaluated and bound\nto their respective argument position, and placeholder arguments (`?`) and ordinal-placeholder arguments \n(`?0`, etc.) are bound to specific argument positions in the resulting partially applied function. As a result,\nexcess arguments passed to a partially applied function have no specific position in which they should be \ninserted. While this behavior differs from `f.bind()`, a fixed argument list allows us to avoid unintentionally\naccepting excess arguments:\n\n```js\n// (a)\n[1, 2, 3].forEach(console.log.bind(console, \"element:\"));\n// prints:\n// element: 1 0 1,2,3\n// element: 2 1 1,2,3\n// element: 3 2 1,2,3\n\n// (b)\n[1, 2, 3].forEach(x =\u003e console.log(\"element:\", x));\n// prints:\n// element: 1\n// element: 2\n// element: 3\n\n// (c)\n[1, 2, 3].forEach(console.log~(\"element:\", ?));\n// prints:\n// element: 1\n// element: 2\n// element: 3\n```\n\nIn the example above, (a) prints extraneous information due to the fact that `forEach` not only passes the\nvalue of each element as an argument, but also the index of the element and the array in which the element\nis contained.\n\nIn the case of (b), the arrow function has a fixed arity. No matter how many excess arguments are passed to\nthe callback, only the `x` parameter is forwarded onto the call.\n\nThe intention of partial application is to emulate a normal call like `console.log(\"element:\", 1)`, where\nevaluation of the \"applied\" portions occurs eagerly with only the placeholder arguments being \"unapplied\".\nThis means that excess arguments have no place to go as part of evaluation. As a result, (c) behaves similar\nto (b) in that only a single argument is accepted by the partial function application and passed through to\n`console.log`.\n\n## Variable Arity: Pass Through Remaining Arguments using `...` \n\nHowever, sometimes you may need the variable arity provided by `Function.prototype.bind`. To support this,\npartial application includes a `...` _rest placeholder argument_ with a specific meaning: Take the _rest_ of\nthe arguments supplied to the partial function and _spread_ them into this position:\n\n```js\nconst writeLog = (header, ...args) =\u003e console.log(header, ...args);\nconst writeAppLog = writeLog~(\"[app]\", ...);\nwriteAppLog(\"Hello\", \"World!\");\n// prints:\n// [app] Hello World!\n\nconst writeAppLogWithBreak = writeAppLog~(..., \"\\n---\");\nwriteAppLogWithBreak(\"End of section\");\n// prints:\n// [app] End of section\n// ---\n```\n\nA partial application may only have a single `...` rest placeholder argument in its argument list, though it\nmay spread in other values using `...expr` as you might in a normal call:\n\n```js\nconst arr = [1, 2, 3];\n\n// The following would be a SyntaxError as the `...` placeholder may only appear once:\n// const g = console.log~(?, ..., ...);\n\n// However, a normal spread is perfectly valid. Below, `...arr` will be evaluated immediately\n// and spread into the list of applied arguments:\nconst g = console.log~(?, ...arr, ...);\ng(\"a\", \"b\", \"c\");                           // prints: a, 1, 2, 3, b, c\n```\n\n# Semantics\n\nA call or `new` expression that uses the `~()` calling convention results in a _partially applied function_.\nThis result is a new function with a parameter for each _placeholder argument_ (i.e., `?`, `?0`, etc.) in the\nargument list. If the partial application contains a `...` _rest placeholder argument_, a rest parameter is\nadded as the final parameter of the resulting _partially applied function_. Any non-placeholder arguments in\nthe argument list becomes fixed in their positions. This is illustrated by the following syntactic conversion:\n\n```js\nconst g = f~(?, 1, ?);\n```\n\nis roughly identical in its behavior to:\n\n```js\nconst g = (() =\u003e {\n  // applied values\n  const _callee = f;\n  const _applied0 = 1;\n\n  // partially applied function\n  return function (_0, _1) { return _callee(_0, _applied0, _1); };\n})();\n```\n\nIn addition to fixing the _callee_ and any _applied arguments_, we also fix the the `this` _receiver_ in the\nresulting _partially applied function_. As such, `o.f~(?)` will maintain `o` as the `this` receiver when calling\n`o.f`. This can be illustrated by the following syntactic conversion:\n\n```js\nconst g = o.f~(?, 1);\n```\n\nis roughly identical in its behavior to:\n\n```js\nconst g = (() =\u003e {\n  // applied values\n  const _receiver_ = o;\n  const _callee = _receiver_.f;\n  const _applied0 = 1;\n\n  // partially applied function\n  return function (_0) { return _callee.call(_receiver_, _0, _applied0); };\n})();\n```\n\nThe following is a list of additional semantic rules:\n\n* Given `f~()`, the expression `f` is evaluated immediately, returning a _partially applied function_ that always calls the value of `f` with no parameters.\n* Given `f~(?)`, the expression `f` is evaluated immediately, returning a _partially applied function_ with a single parameter that always calls the value of `f` with that parameter as its sole argument.\n* Given `f~(?, x)`, the non-placeholder argument `x` is evaluated immediately and fixed in its position.\n* Given `f~(?)`, excess arguments supplied to the partially applied function result are ignored.\n* Given `f~(?, ?)` the partially applied function result will have a parameter for each placeholder \n  token that is supplied in that token's position in the argument list.\n* Given `f~(this, ?)`, the `this` in the argument list is the lexical `this`.\n* Given `f~(?)`, the `this` receiver of the function `f` is fixed as `undefined` in the partially\n  applied function result.\n* Given `f~(?)`, the `length` of the partially applied function result is equal to the number of `?` placeholder tokens in the\n  argument list.\n* Given `f~(?)`, the `name` of the partially applied function result is `f.name`.\n* Given `o.f~(?)`, the references to `o` and `o.f` are evaluated immediately.\n* Given `o.f~(?)`, the `this` receiver of the function `o.f` is fixed as `o` in the partially \n  applied function result.\n* Given `new C~()`, the result is a function that returns a new instance of `C`.\n  * NOTE: This is not easily achievable with `.bind()` today (if at all).\n* Given `const g = new C~()`, `g.name` is `\"bound C\"`.\n* Given `const g = new C~()`, `g.length` is `0` (based on length derived from placeholder arguments).\n* Given `const g = new C~()`, `Object.getPrototypeOf(g)` is `C`.\n* Given `new (f~())`, the partial application of `f` returns a new function that can be constructed via `new`, similar\n  to `new (f.bind(null))`.\n* Given `f?.~()` (a partially applied, optional call), if `f` is `null` or `undefined`, the result is `undefined`. Otherwise,\n  the result is the partial application of `f~()`.\n* Given `o?.f~()` (a partially applied call in an optional chain), if `o` is `null` or `undefined`, the result is `undefined`. \n  Otherwise, the result is the partial application of `o.f~()`.\n\n# Parsing\n\nWhile this proposal leverages the existing `?` token used in conditional expressions, it does not\nintroduce parsing ambiguity as the `?` placeholder token can only be used in an argument list and \ncannot have an expression immediately preceding it (e.g. `f~(a?` is definitely a conditional \nwhile `f~(?` is definitely a placeholder).\n\n# Grammar\n\n```grammarkdown\nMemberExpression[Yield, Await] :\n  ...\n  `new` MemberExpression[?Yield, ?Await] Arguments[?Yield, ?Await, ~Partial]\n\nCallExpression[Yield, Await] :\n  CallExpression[?Yield, ?Await] Arguments[?Yield, ?Await, +Partial]\n\nCoverCallExpressionAndAsyncArrowHead[Yield, Await]:\n  MemberExpression[?Yield, ?Await] Arguments[?Yield, ?Await, +Partial]\n\nCallMemberExpression[Yield, Await] :\n  MemberExpression[?Yield, ?Await] Arguments[?Yield, ?Await, +Partial]\n\nSuperCall[Yield, Await] :\n  `super` Arguments[?Yield, ?Await, ~Partial]\n\nOptionalChain[Yield, Await] :\n  `?.` Arguments[?Yield, ?Await, +Partial]\n  ...\n  OptionalChain[?Yield, ?Await] Arguments[?Yield, ?Await, +Partial]\n  ...\n\nArguments[Yield, Await, Partial] :\n  `(` ArgumentList[?Yield, ?Await, ~Partial] `)`\n  `(` ArgumentList[?Yield, ?Await, ~Partial], `,` `)`\n  [+Partial] [no LineTerminator here] `~` `(` ArgumentList[?Yield, ?Await, +Partial] `)`\n  [+Partial] [no LineTerminator here] `~` `(` ArgumentList[?Yield, ?Await, +Partial] `,` `)`\n\nArgumentList[Yield, Await, Partial] :\n  AssignmentExpression[+In, ?Yield, ?Await]\n  `...` AssignmentExpression[+In, ?Yield, ?Await]\n  ArgumentList[?Yield, ?Await, ?Partial] `,` AssignmentExpression[+In, ?Yield, ?Await]\n  ArgumentList[?Yield, ?Await, ?Partial] `,` `...` AssignmentExpression[+In, ?Yield, ?Await]\n  [+Partial] `?` DecimalIntegerLiteral?\n  [+Partial] `...`\n  [+Partial] ArgumentList[?Yield, ?Await, ?Partial] `,` `?` DecimalIntegerLiteral?\n  [+Partial] ArgumentList[?Yield, ?Await, ?Partial] `,` `...`\n```\n\n\u003e NOTE: It is a **SyntaxError** for a partial call to have more than one `...` placeholder.\n\n# Examples\n\n**Logging with Timestamps**\n```js\nconst log = console.log~({ toString() { return `[${new Date().toISOString()}]` } }, ?);\nlog(\"test\"); // [2018-07-17T23:25:36.984Z] test\n```\n\n**Event Handlers**\n```js\nbutton.addEventListener(\"click\", this.onClick~(?));\n```\n\n**Bound methods**\n```js\nclass Collator {\n  constructor() {\n    this.compare = this.compare~(?, ?);\n  }\n  compare(a, b) { ... }\n}\n```\n\n**Passing state through callbacks**\n```js\n// doWork expects a callback of `(err, value) =\u003e void`\nfunction doWork(callback) { ... }\nfunction onWorkCompleted(err, value, state) { ... }\ndoWork(onWorkCompleted~(?, ?, { key: \"value\" }));\n```\n\n**Uncurry `this`**\n```js\nconst slice = Array.prototype.slice.call~(?, ?, ?);\nslice({ 0: \"a\", 1: \"b\", length: 2 }, 1, 2); // [\"b\"]\n```\n\nYou can also find a number of desugaring examples in [EXAMPLES.md](EXAMPLES.md).\n\n# Relationships to Other Proposals/Language Features\n\n## Partial Application and Pipeline\n\nThe [Pipeline Proposal](https://github.com/tc39/proposal-pipeline-operator) recently advanced to Stage 2 using the\nHack-style for pipelines. While partial application was intended to dovetail with F#-style pipelines, this recent\nchange does not diminish the value of partial application. In fact, the move to Hack-style mitigates the\nrequirement that partial application *not* have a prefix token, which was a blocking concern from some members\nof TC39. That said, there is still a place for partial application in conjunction with pipeline:\n\n```js\nconst add = (x, y) =\u003e x + y;\nconst greaterThan = (x, y) =\u003e x \u003e y;\n\n// using Hack-style pipes\nelements\n  |\u003e map(^, add~(?, 1))\n  |\u003e filter(^, greaterThan~(?, 5));\n```\n\nThis creates a visual distinction between the topic variable in a Hack-style pipe (`^` currently, although that\nhas not been finalized), a partial call (`~()`), and a placeholder argument (`?`) that should aid in readability\nand improve developer intuition about their code will evaluate.\n\n## Partial Application and Optional Chaining\n\nPartial Application is supported within an _OptionalChain_, per the [Semantics](#semantics) and [Grammar](#grammar) \nsections, above. As partial application is tied to _Arguments_, the `~(` calling convention would follow `?.` in an \noptional call:\n\n```js\nconst maybeAddOne = add?.~(?, 1); // undefined | Function\nconst maybeLog = console?.log~(?); // undefined | Function\n```\n\nPer the semantics of _OptionalChain_, in both of the examples above the `?.` token short-circuits evaluation of the \nrest of the chain. As a result, if the _callee_ is nullish then the result of both expressions would be `undefined`.\nIf the _callee_ is not nullish, then the result would be the partial application of the _callee_.\n\n# Open Questions/Concerns\n\n## Choosing a different token than `?`\n\nThere have been suggestions to consider another token aside from `?`, given that optional\nchaining may be using `?.` and nullish coalesce may be using `??`. It is our opinion that\nsuch a token change is unnecessary, as `?` may _only_ be used on its own in an argument list\nand _may not_ be combined with these operators (e.g. `f~(??.a ?? c)` is not legal). The `?`\ntoken's visual meaning best aligns with this proposal, and its fairly easy to write similarly\ncomplex expressions today using existing tokens (e.g. `f(+i+++j-i---j)` or `f([[][]][[]])`).\nA valid, clean example of both partial application, optional chaining, and nullish coalesce is\nnot actually difficult to read in most cases: `f~(?, a?.b ?? c)`.\n\n# Definitions\n\n- _Partial Application_ \u0026mdash; A call or `new` expression with zero or more _placeholder arguments_, where _applied expressions_ are immediately evaluated and _fixed_ in their respective positions in the invocation.  \n  A _partial application_ is denoted by an argument list surrounded by `~()`  \n  Example: `f~()`\n- _Partially Applied Function_ \u0026mdash; A function that is the result of a _partial application_.\n- _Applied Expressions_ \u0026mdash; The _callee_, _receiver_, and any _non-placeholder arguments_ of a _partial application_.  \n  Also: _applied_.  \n  Antonyms: _unapplied_.\n- _Callee_ \u0026mdash; The value of the function or method to be invoked (for a call) or instantiated (for `new` expressions).\n- _Receiver_ \u0026mdash; If the _Callee_ is a method invocation, the _receiver_ is the object that will be passed to the call as its `this` binding.\n- _Fix_ \u0026mdash; Eagerly evaluate an expression and store its position within a _partially application_.  \n  Also: _fixed_, _fixing_.\n- _Non-Placeholder Argument_ \u0026mdash; An _Applied Expression_ that takes up an entire argument position.\n- _Placeholder Argument_ \u0026mdash; An argument that is not yet _applied_ in a _partial application_. A _placeholder argument_ results in \n  one or more parameter bindings in a resulting _partially applied function_.\n- _Non-Ordinal Placeholder Argument_ \u0026mdash; A _placeholder argument_ representing a single unapplied argument. _Non-ordinal placeholder \n  arguments_ are implicitly ordered sequentially from left to right.  \n  A _non-ordinal placeholder argument_ is denoted by a `?` token that takes up an entire an argument position.  \n  Example: `f~(?)`\n- _Ordinal Placeholder Argument_ \u0026mdash; A _placeholder argument_ representing a single unapplied argument with a specified ordinal position\n  in the parameter list of the resulting _partially applied function_.  \n  An _ordinal placeholder argument_ is denoted by a `?` token followed by an unsigned integer indicating the ordinal position of the \n  resulting parameter.  \n  Example: `f~(?1, ?0)`\n- _Rest Placeholder Argument_ \u0026mdash; A _placeholder argument_ representing any excess arguments passed to the resulting _partially applied\n  function_.  \n  A _rest placeholder argument_ is denoted by a `...` token that takes up an entire argument position.  \n  Example: `f~(...)`\n\n# Resources\n\n- [Overview Slides](https://raw.githubusercontent.com/tc39/proposal-partial-application/main/assets/PartialApplication-tc39.pptx)\n\n# TODO\n\nThe following is a high-level list of tasks to progress through each stage of the [TC39 proposal process](https://tc39.github.io/process-document/):\n\n### Stage 1 Entrance Criteria\n\n* [x] Identified a \"[champion][Champion]\" who will advance the addition.  \n* [x] [Prose][Prose] outlining the problem or need and the general shape of a solution.  \n* [x] Illustrative [examples][Examples] of usage.  \n* [x] ~High-level API~ _(proposal does not introduce an API)_.  \n\n### Stage 2 Entrance Criteria\n\n* [x] [Initial specification text][Specification].  \n* [ ] _Optional_. [Transpiler support][Transpiler].  \n\n### Stage 3 Entrance Criteria\n\n* [ ] [Complete specification text][Specification].  \n* [ ] Designated reviewers have [signed off][Stage3ReviewerSignOff] on the current spec text.  \n* [ ] The ECMAScript editor has [signed off][Stage3EditorSignOff] on the current spec text.  \n\n### Stage 4 Entrance Criteria\n\n* [ ] [Test262](https://github.com/tc39/test262) acceptance tests have been written for mainline usage scenarios and [merged][Test262PullRequest].  \n* [ ] Two compatible implementations which pass the acceptance tests: [\\[1\\]][Implementation1], [\\[2\\]][Implementation2].  \n* [ ] A [pull request][Ecma262PullRequest] has been sent to tc39/ecma262 with the integrated spec text.  \n* [ ] The ECMAScript editor has signed off on the [pull request][Ecma262PullRequest].  \n\n\u003c!-- The following are shared links used throughout the README: --\u003e\n\n[Champion]: #status\n[Prose]: #proposal\n[Examples]: #examples\n[Specification]: https://tc39.es/proposal-partial-application\n[Transpiler]: #todo\n[Stage3ReviewerSignOff]: #todo\n[Stage3EditorSignOff]: #todo\n[Test262PullRequest]: #todo\n[Implementation1]: #todo\n[Implementation2]: #todo\n[Ecma262PullRequest]: #todo\n","funding_links":[],"categories":["HTML"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftc39%2Fproposal-partial-application","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftc39%2Fproposal-partial-application","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftc39%2Fproposal-partial-application/lists"}