You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: rust/main/chains/hyperlane-aleo/src/types.rs
+5-2Lines changed: 5 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -4,8 +4,11 @@ use snarkvm::{
4
4
};
5
5
use snarkvm_console_account::Field;
6
6
7
-
/// Default Network that we go to
8
-
/// We need this as aleo annotates every type - even types that don't change with a different network
7
+
// This actually works for all networks. I've raised this with the Aleo team, but the type annotation here doesn't actually change the underlying type.
8
+
// The Aleo VM types all inherit a generic Network type, but that Type is not relevant for many structs of Aleo and is supposed to be more of an additional information for the internal VM processing.
9
+
// They need this, because they generate ZK Proofs differently for different networks but the actual data of these types are the same across all Networks.
10
+
// We pass CurrentNetwork into a lot of types, because we don't have to generate ZK Proofs in almost every situation - except when submitting a TX. There is one exception to this and that is when parsing/handling with Blocks.
11
+
// The Block type verifies its validity on creation and that changes based on the Network type, thats why we have to pass the correct Type when dealing with blocks.
0 commit comments