mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-01 03:21:02 +00:00
[xcm] Foreign global consensus parachain LocationToAccountId converter (#7016)
* **Foreign** global consensus parachain LocationToAccount converter * Review fix * Added `UniversalLocation` + `ensure_is_remote` handling * Added unique id to encoding * Update xcm/xcm-builder/src/location_conversion.rs Co-authored-by: Gavin Wood <gavin@parity.io> * Re-export `ensure_is_remote` * Test * fmt * Update xcm/xcm-builder/src/location_conversion.rs * Update xcm/xcm-builder/src/universal_exports.rs Co-authored-by: Gavin Wood <gavin@parity.io> --------- Co-authored-by: parity-processbot <> Co-authored-by: Gavin Wood <gavin@parity.io>
This commit is contained in:
@@ -23,7 +23,11 @@ use xcm::prelude::*;
|
||||
use xcm_executor::traits::{validate_export, ExportXcm};
|
||||
use SendError::*;
|
||||
|
||||
fn ensure_is_remote(
|
||||
/// Returns the network ID and consensus location within that network of the remote
|
||||
/// location `dest` which is itself specified as a location relative to the local
|
||||
/// chain, itself situated at `universal_local` within the consensus universe. If
|
||||
/// `dest` is not a location in remote consensus, then an error is returned.
|
||||
pub fn ensure_is_remote(
|
||||
universal_local: impl Into<InteriorMultiLocation>,
|
||||
dest: impl Into<MultiLocation>,
|
||||
) -> Result<(NetworkId, InteriorMultiLocation), MultiLocation> {
|
||||
|
||||
Reference in New Issue
Block a user