summaryrefslogtreecommitdiffstats
path: root/src/test/ui/hygiene/dollar-crate-modern.rs
blob: eb176fed87c0041203c2c95c96fa5c07b66dfcf7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
// Make sure `$crate` and `crate` work in for basic cases of nested macros.

// check-pass
// aux-build:intercrate.rs

#![feature(decl_macro)]

extern crate intercrate;

// `$crate`
intercrate::uses_dollar_crate_modern!();

intercrate::define_uses_dollar_crate_modern_nested!(uses_dollar_crate_modern_nested);
uses_dollar_crate_modern_nested!();

intercrate::define_uses_dollar_crate_legacy_nested!();
uses_dollar_crate_legacy_nested!();

// `crate`
intercrate::uses_crate_modern!();

intercrate::define_uses_crate_modern_nested!(uses_crate_modern_nested);
uses_crate_modern_nested!();

fn main() {}