Here is how it would look with square brackets:
It occurs to me that the "capture clause" could (and probably should) go
before the name, if we allowed it on nested fn item declarations:
fn no_env(a: A, b: B) {...}
fn<copy> boxed_env_1(a: A, b: B) {...}
fn<copy a; move b> boxed_env_2<A,B>(a: A, b: B) {...}
fn<send; copy a; move b> unique_env<A,B>(a: A, b: B) {...}
In this way there is no ambiguity at all. (Note that we don't allow
function types to have generic parameters at the moment)
Niko
_______________________________________________
Rust-dev mailing list
[email protected]
https://mail.mozilla.org/listinfo/rust-dev