2019-08-21 12:53:11 +03:00
|
|
|
// Regression test for the issue #63460.
|
|
|
|
|
2024-02-16 20:02:50 +00:00
|
|
|
//@ check-pass
|
2019-08-21 12:53:11 +03:00
|
|
|
|
|
|
|
#[macro_export]
|
|
|
|
macro_rules! separator {
|
|
|
|
() => { "/" };
|
|
|
|
}
|
|
|
|
|
|
|
|
#[macro_export]
|
|
|
|
macro_rules! concat_separator {
|
|
|
|
( $e:literal, $($other:literal),+ ) => {
|
|
|
|
concat!($e, $crate::separator!(), $crate::concat_separator!($($other),+))
|
|
|
|
};
|
|
|
|
( $e:literal ) => {
|
|
|
|
$e
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
println!("{}", concat_separator!(2, 3, 4))
|
|
|
|
}
|