rfc:closure_self_reference
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
rfc:closure_self_reference [2023/06/03 18:37] – danack | rfc:closure_self_reference [2023/06/03 21:00] – typo. danack | ||
---|---|---|---|
Line 2: | Line 2: | ||
* Version: 1.0 | * Version: 1.0 | ||
* Date: 2023-06-03 | * Date: 2023-06-03 | ||
- | * Author: Danack | + | * Author: Danack, KapitanOczywisty |
- | * Status: | + | * Status: |
* First Published at: https:// | * First Published at: https:// | ||
Line 54: | Line 54: | ||
===== Syntax choices ===== | ===== Syntax choices ===== | ||
- | There are a plethora of possible syntax choices. Those that have been though | + | There are a plethora of possible syntax choices. Those that have been thought |
==== A constant ==== | ==== A constant ==== | ||
Line 105: | Line 105: | ||
<code php> | <code php> | ||
- | $fibonacci = function $fn(int $n) as $fn { | + | $fibonacci = function $fn(int $n) { |
if ($n === 0) return 0; | if ($n === 0) return 0; | ||
if ($n === 1) return 1; | if ($n === 1) return 1; | ||
Line 147: | Line 147: | ||
- | ===== Syntax choice ===== | + | ===== Syntax choice |
- | The following syntaxes are excluded for the reasons listed: | + | Of the syntaxes considered, the following syntaxes are excluded for the reasons listed: |
* A constant. Although this could work it has multiple aesthetic downsides of being verbose, ugly, and just not very language-y. | * A constant. Although this could work it has multiple aesthetic downsides of being verbose, ugly, and just not very language-y. |
rfc/closure_self_reference.txt · Last modified: 2023/06/03 21:01 by danack