Re: Examples comparing Bl ock Scoped RAII and Context Managers
| From: | Rowan Tommins [IMSoP] | Date: | Sat, 13 Dec 2025 17:07:43 +0000 |
| Subject: | Re: Examples comparing Bl ock Scoped RAII and Context Managers | ||
| References: | 1 2 3 4 5 6 7 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-129604@lists.php.net to get a copy of this message | ||
On 13 December 2025 15:58:22 GMT, Larry Garfield <larry@garfieldtech.com> wrote:
>Rowan (or anyone else), did you have thoughts here? Would => be a more self-explanatory
>symbol to use for the context manager block?
Yes, sorry, I must have replied in my head. I think that does make it clearer that one value
produces the other, rather than just being assigned or aliased to it.
Although the most common use is key=>value, we also have fn()=>return_expression and
get=>property_expression.
Rowan Tommins
[IMSoP]