kojira on Nostr: use serde_json::Result; をいれるだけで the question mark operation (`?`) ...
use serde_json::Result;
をいれるだけで
the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait
the following other types implement trait `FromResidual<R>`:
<std::result::Result<T, F> as FromResidual<Yeet<E>>>
<std::result::Result<T, F> as FromResidual<std::result::Result<Infallible, E>>>
required for `std::result::Result<bool, serde_json::Error>` to implement `FromResidual<std::result::Result<Infallible, std::io::Error>>`
になるんどす…
初心者過ぎて何もわからん…
Published at
2023-03-14 15:15:37Event JSON
{
"id": "a8ed6abccdc9f9a0cf5bab80df5c6e2e8077c74621fb99dddd35d521c15c7a57",
"pubkey": "b3e43e8cc7e6dff23a33d9213a3e912d895b1c3e4250240e0c99dbefe3068b5f",
"created_at": 1678806937,
"kind": 1,
"tags": [
[
"p",
"4d39c23b3b03bf99494df5f3a149c7908ae1bc7416807fdd6b34a31886eaae25"
],
[
"p",
"b3e43e8cc7e6dff23a33d9213a3e912d895b1c3e4250240e0c99dbefe3068b5f"
],
[
"e",
"3fc97ee564e6f0f164482157ef2e03a4989177f947a8e78e25abc1ebec6174c4",
"",
"root"
],
[
"e",
"3fc97ee564e6f0f164482157ef2e03a4989177f947a8e78e25abc1ebec6174c4",
"",
"reply"
]
],
"content": "use serde_json::Result;\nをいれるだけで\nthe question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait\nthe following other types implement trait `FromResidual\u003cR\u003e`:\n \u003cstd::result::Result\u003cT, F\u003e as FromResidual\u003cYeet\u003cE\u003e\u003e\u003e\n \u003cstd::result::Result\u003cT, F\u003e as FromResidual\u003cstd::result::Result\u003cInfallible, E\u003e\u003e\u003e\nrequired for `std::result::Result\u003cbool, serde_json::Error\u003e` to implement `FromResidual\u003cstd::result::Result\u003cInfallible, std::io::Error\u003e\u003e`\nになるんどす…\n初心者過ぎて何もわからん…",
"sig": "af97f1c687484c32331d651ef32f8c060b2be0c3e6d7c3e4193589abc80c6d3726534fda263cf51d15bf431e83960130d05eeb1c272483417140951f5ae719e5"
}