Skip to content

Can double-ref (&&x) parsing be fixed? #11227

Closed
@brson

Description

@brson

This is very unfortunate.

fn main() {
    let x = ~~1;
    let y = &&x;
}
brian@brian-X1:~/dev/rust4/build$ x86_64-unknown-linux-gnu/stage1/bin/rustc test.rs
test.rs:3:12: 3:14 error: unexpected token: `&&`
test.rs:3     let y = &&x;
                      ^~

Nominating.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-grammarArea: The grammar of RustP-lowLow priority

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions