I've been playing with some ways to work together with sending and ownership, and stumbled across case I'm not sure how to treat:
class NonSendable {
}
func foo(bar: borrowing sending NonSendable) { // error: 'sending' cannot be used together with 'borrowing'
}
I went over to proposal to check notes on why, and the beginning of section makes total sense to me:
When a call passes an argument to a sending parameter, the caller cannot use the argument value again after the callee returns. By default sending on a function parameter implies that the callee consumes the parameter. [emphasis mine]
But then it also states that this can be opt-in by pairing with explicit ownership parameters, so that using borrowing with sending is a valid pair, yet the compiler doesn't allow this. Is that an issue in the proposal text or the compiler?