]> git.lizzy.rs Git - rust.git/commit
Rollup merge of #34495 - jseyfried:only_ident_macro_invocations, r=eddyb
authorManish Goregaokar <manishsmail@gmail.com>
Wed, 29 Jun 2016 15:51:22 +0000 (21:21 +0530)
committerGitHub <noreply@github.com>
Wed, 29 Jun 2016 15:51:22 +0000 (21:21 +0530)
commit8886818a9ab3e6c52651038d4e22e2d51b932bb9
treeb7df117c5afe9c843b3492a3961e41b1b7b7a164
parent2a0c2c3b3a0c7291f6160f9cf4178ecbdb920f04
parentb4611b1ff29d93ba9a03932b316935cbfd076ed9
Rollup merge of #34495 - jseyfried:only_ident_macro_invocations, r=eddyb

Forbid type parameters and global paths in macro invocations

Fixes #28558.
This is a [breaking-change]. For example, the following would break:
```rust
macro_rules! m { () => { () } }
fn main() {
    m::<T>!(); // Type parameters are no longer allowed in macro invocations
    ::m!(); // Global paths are no longer allowed in macro invocations
}
```
Any breakage can be fixed by removing the type parameters or the leading `::` (respectively).

r? @eddyb
src/libsyntax/ext/expand.rs