XCM canonicalize + prepend_with fix (#3269)

* canonicalize + prepend_with fix

* fix doc

* not needed

* better docs, and more deterministic logic

* one more test

* Update xcm/src/v0/multi_location.rs

* Update multi_location.rs

Co-Authored-By: parity-processbot <>

* follow style guide

Co-Authored-By: parity-processbot <>

* oops

* Update xcm/src/v0/multi_location.rs

Co-authored-by: Robert Habermeier <rphmeier@gmail.com>

* Update xcm/src/v0/multi_location.rs

Co-authored-by: Robert Habermeier <rphmeier@gmail.com>
This commit is contained in:
Shawn Tabrizi
2021-07-02 12:31:13 -04:00
committed by GitHub
parent 7b054b3c77
commit e0f481ca6c
2 changed files with 130 additions and 16 deletions
+8
View File
@@ -138,6 +138,14 @@ pub enum Junction {
}
impl Junction {
/// Returns true if this junction is a `Parent` item.
pub fn is_parent(&self) -> bool {
match self {
Junction::Parent => true,
_ => false,
}
}
/// Returns true if this junction can be considered an interior part of its context. This is generally `true`,
/// except for the `Parent` item.
pub fn is_interior(&self) -> bool {