2022-08-27 20:35:44 -05:00
|
|
|
// Regression test for https://github.com/rust-lang/rust/issues/100973
|
|
|
|
|
|
|
|
#![feature(no_core)]
|
|
|
|
#![no_core]
|
|
|
|
|
2023-05-22 12:17:52 -05:00
|
|
|
// @set m1 = "$.index[*][?(@.name == 'm1' && @.inner.module)].id"
|
|
|
|
// @is "$.index[*][?(@.name == 'm1')].inner.module.items" []
|
|
|
|
// @is "$.index[*][?(@.name == 'm1')].inner.module.is_stripped" true
|
2022-08-27 20:35:44 -05:00
|
|
|
mod m1 {
|
|
|
|
pub fn f() {}
|
|
|
|
}
|
2023-05-22 12:17:52 -05:00
|
|
|
// @set m2 = "$.index[*][?(@.name == 'm2' && @.inner.module)].id"
|
|
|
|
// @is "$.index[*][?(@.name == 'm2')].inner.module.items" []
|
|
|
|
// @is "$.index[*][?(@.name == 'm2')].inner.module.is_stripped" true
|
2022-08-27 20:35:44 -05:00
|
|
|
mod m2 {
|
|
|
|
pub fn f(_: u8) {}
|
|
|
|
}
|
|
|
|
|
2023-05-22 12:17:52 -05:00
|
|
|
// @set m1_use = "$.index[*][?(@.docs=='m1 re-export')].id"
|
|
|
|
// @is "$.index[*].inner.import[?(@.name=='m1')].id" $m1
|
|
|
|
// @is "$.index[*].inner.import[?(@.name=='m1')].glob" true
|
|
|
|
/// m1 re-export
|
2022-08-27 20:35:44 -05:00
|
|
|
pub use m1::*;
|
2023-05-22 12:17:52 -05:00
|
|
|
// @set m2_use = "$.index[*][?(@.docs=='m2 re-export')].id"
|
|
|
|
// @is "$.index[*].inner.import[?(@.name=='m2')].id" $m2
|
|
|
|
// @is "$.index[*].inner.import[?(@.name=='m2')].glob" true
|
|
|
|
/// m2 re-export
|
2022-08-27 20:35:44 -05:00
|
|
|
pub use m2::*;
|
|
|
|
|
2023-05-22 12:17:52 -05:00
|
|
|
// @ismany "$.index[*].inner.module[?(@.is_crate==true)].items[*]" $m1_use $m2_use
|