2022-09-11 14:32:47 -05:00
|
|
|
//@ aux-build: foreign_trait.rs
|
|
|
|
extern crate foreign_trait;
|
|
|
|
|
|
|
|
/// ForeignTrait id hack
|
|
|
|
pub use foreign_trait::ForeignTrait as _;
|
2023-05-22 12:17:52 -05:00
|
|
|
// @set ForeignTrait = "$.index[*][?(@.docs=='ForeignTrait id hack')].inner.import.id"
|
2022-09-11 14:32:47 -05:00
|
|
|
|
|
|
|
pub struct LocalStruct;
|
|
|
|
// @set LocalStruct = "$.index[*][?(@.name=='LocalStruct')].id"
|
|
|
|
|
|
|
|
/// foreign for local
|
|
|
|
impl foreign_trait::ForeignTrait for LocalStruct {}
|
|
|
|
|
|
|
|
// @set impl = "$.index[*][?(@.docs=='foreign for local')].id"
|
2023-05-22 12:17:52 -05:00
|
|
|
// @is "$.index[*][?(@.docs=='foreign for local')].inner.impl.for.resolved_path.id" $LocalStruct
|
|
|
|
// @is "$.index[*][?(@.docs=='foreign for local')].inner.impl.trait.id" $ForeignTrait
|
2022-09-11 14:32:47 -05:00
|
|
|
|
2023-05-22 12:17:52 -05:00
|
|
|
// @has "$.index[*][?(@.name=='LocalStruct')].inner.struct.impls[*]" $impl
|