File tree 3 files changed +18
-8
lines changed
src/test/rustdoc-json/reexport
3 files changed +18
-8
lines changed Original file line number Diff line number Diff line change 4
4
#![ feature( no_core) ]
5
5
6
6
// @is glob_extern.json "$.index[*][?(@.name=='mod1')].kind" \"module\"
7
- // @is glob_extern.json "$.index[*][?(@.name=='mod1')].inner.is_stripped" "true"
7
+ // @is - "$.index[*][?(@.name=='mod1')].inner.is_stripped" "true"
8
8
mod mod1 {
9
9
extern "C" {
10
- // @has - "$.index[*][?(@.name=='public_fn')].id"
10
+ // @set public_fn_id = - "$.index[*][?(@.name=='public_fn')].id"
11
11
pub fn public_fn ( ) ;
12
12
// @!has - "$.index[*][?(@.name=='private_fn')]"
13
13
fn private_fn ( ) ;
14
14
}
15
+ // @count - "$.index[*][?(@.name=='mod1')].inner.items[*]" 1
16
+ // @has - "$.index[*][?(@.name=='mod1')].inner.items[*]" $public_fn_id
17
+ // @set mod1_id = - "$.index[*][?(@.name=='mod1')].id"
15
18
}
16
19
17
20
// @is - "$.index[*][?(@.kind=='import')].inner.glob" true
21
+ // @is - "$.index[*][?(@.kind=='import')].inner.id" $mod1_id
18
22
pub use mod1:: * ;
Original file line number Diff line number Diff line change 1
1
// aux-build:pub-struct.rs
2
2
3
- // Test for the ICE in rust/83057
4
- // Am external type re-exported with different attributes shouldn't cause an error
3
+ // Test for the ICE in https://github.com/ rust-lang/rust/issues /83057
4
+ // An external type re-exported with different attributes shouldn't cause an error
5
5
6
6
#![ no_core]
7
7
#![ feature( no_core) ]
Original file line number Diff line number Diff line change 1
- // Test for the ICE in rust/83720
1
+ // Test for the ICE in https://github.com/ rust-lang/rust/issues /83720
2
2
// A pub-in-private type re-exported under two different names shouldn't cause an error
3
3
4
4
#![ no_core]
7
7
// @is private_two_names.json "$.index[*][?(@.name=='style')].kind" \"module\"
8
8
// @is private_two_names.json "$.index[*][?(@.name=='style')].inner.is_stripped" "true"
9
9
mod style {
10
- // @has - "$.index[*]( ?(@.name=='Color')) "
10
+ // @set color_struct_id = - "$.index[*][ ?(@.kind=='struct' && @. name=='Color')].id "
11
11
pub struct Color ;
12
12
}
13
13
14
- // @has - "$.index[*][?(@.kind=='import' && @.inner.name=='Color')]"
14
+ // @is - "$.index[*][?(@.kind=='import' && @.inner.name=='Color')].inner.id" $color_struct_id
15
+ // @set color_export_id = - "$.index[*][?(@.kind=='import' && @.inner.name=='Color')].id"
15
16
pub use style:: Color ;
16
- // @has - "$.index[*][?(@.kind=='import' && @.inner.name=='Colour')]"
17
+ // @is - "$.index[*][?(@.kind=='import' && @.inner.name=='Colour')].inner.id" $color_struct_id
18
+ // @set colour_export_id = - "$.index[*][?(@.kind=='import' && @.inner.name=='Colour')].id"
17
19
pub use style:: Color as Colour ;
20
+
21
+ // @count - "$.index[*][?(@.name=='private_two_names')].inner.items[*]" 2
22
+ // @has - "$.index[*][?(@.name=='private_two_names')].inner.items[*]" $color_export_id
23
+ // @has - "$.index[*][?(@.name=='private_two_names')].inner.items[*]" $colour_export_id
You can’t perform that action at this time.
0 commit comments