Well, that explains why it’s technically possible.
As for why Option<&str> is preferrable then: It hides away your internals. Your caller should only care whether they can get the value or not (Some vs. None), not what the precise reason is. That reason or your internal structure might change.
since: my first project (codeberg.org)
This is my first project in rust, called: since. A small tool to filter logfiles or any other files with a timestamp in it, by a given timestamp....