diem_types/account_config/constants/
coins.rs1use crate::account_config::constants::{
9 from_currency_code_string, CORE_CODE_ADDRESS,
10};
11use move_core_types::language_storage::{StructTag, TypeTag};
12
13pub const XDX_NAME: &str = "XDX";
14pub const XUS_NAME: &str = "XUS";
15
16pub fn xus_tag() -> TypeTag {
17 TypeTag::Struct(StructTag {
18 address: CORE_CODE_ADDRESS,
19 module: from_currency_code_string(XUS_NAME).unwrap(),
20 name: from_currency_code_string(XUS_NAME).unwrap(),
21 type_params: vec![],
22 })
23}
24
25pub fn xdx_type_tag() -> TypeTag {
26 TypeTag::Struct(StructTag {
27 address: CORE_CODE_ADDRESS,
28 module: from_currency_code_string(XDX_NAME).unwrap(),
29 name: from_currency_code_string(XDX_NAME).unwrap(),
30 type_params: vec![],
31 })
32}