Jeff Martin on Nostr: TIL in #Rust, if you name a variable `_`, it gets immediately dropped, but a variable ...
TIL in #Rust, if you name a variable `_`, it gets immediately dropped, but a variable named `_a` won't get dropped until the end of the scope.
So don't name your channel receivers `_` if you want the senders to keep working, even if you never intend to read from the receiver.

Published at
2023-10-20 22:28:24Event JSON
{
"id": "0be3f2b36a4dd2e65d9003cc22843fc539ee308c326b9522810c38d23780d4a9",
"pubkey": "4b06a99655066ca3e1a19ecc4bd5c5fd5d0f106a319a8cfb3c414bdff9e17c27",
"created_at": 1697840904,
"kind": 1,
"tags": [
[
"t",
"rust"
],
[
"emoji",
"themoreyouknow",
"https://files.gladtech.social/custom_emojis/images/000/040/308/original/14322b4755657cf3.png"
],
[
"proxy",
"https://gladtech.social/users/cuchaz/statuses/111269701509445602",
"activitypub"
]
],
"content": "TIL in #Rust, if you name a variable `_`, it gets immediately dropped, but a variable named `_a` won't get dropped until the end of the scope.\n\nSo don't name your channel receivers `_` if you want the senders to keep working, even if you never intend to read from the receiver. :themoreyouknow:",
"sig": "61b4f9e8e45b6b27675b6f07b83759360db0257a3cbf0810aa435c937ebc166681357ccf610ee22ac65e10b63ea16f342ddaa282451415258a5e0dc4f3fac2b9"
}