Move Expressions

22 points by robinhundt


ssokolow

In this case, there are two aspects I disagree with:

First, I think the magical keyword-that-looks-like-a-function syntax and the associated inconsistency that needs to be taught and remembered is going in the wrong direction. This is the reason that macro invocation requires ! to distinguish it from function calls.

Second, I think that existing move is already bad enough as a means of burying "this will be transferred to another thread/task/whatever and likely outlive this scope" inside the body of the closure rather than in its signature. This would double down on allowing that sort of thing.

In both cases, I think this proposal would go in the direction of less consistency with the design philosophy of the language's existing syntax and add more "outsized complexity".