I’ve always wondered this, but as this was a minor nit, I thought it was not worth discussing. But considering 1.0 as a final deadline for all the breaking changes, I finally took my courage to write this.
How about renaming FnOnce into FnMove?
Reading the IRC log happened a month ago, there was a similar suggestion:
<p1start> reem: But with the current system, Fn/FnMut matches with Deref/DerefMut
<p1start> And Index/IndexMut. Which is why I’d prefer FnMove to FnOnce: Deref/DerefMut/DerefMove : Index/IndexMut/IndexMove : Fn/FnMut/FnMove would be so neat
And I have the similar feelings. Every other aspect of the language consistently uses “”, “mut”, “move” to call three mechanisms that it uses, so being consistent with them would be good to see.
Possible downsides of this change are:
- Personally,
FnMove does not sound as attractive as FnOnce does. FnOnce emphasizes exactly what it does - it can only be called once!
- It may confuse users who may think
move || and FnMove are somewhat related. They are two different things, so labeling them with completely different names would be a better idea.
As I said earlier, this is just bikeshedding. Also, FnOnce and family are already marked as stable. But I do think that this would be the last chance to fix it, if I understand the problem correctly.
Thoughts?