-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ROLL-16 Tickets #34
base: master
Are you sure you want to change the base?
ROLL-16 Tickets #34
Conversation
@@ -42,6 +42,7 @@ pub struct LayeredStore<Backend: StoreBackend> { | |||
backend: Backend, | |||
pending_state: HashMap<String, Option<(DynStoreType, StoreTypeSer)>>, | |||
modified_keys: HashSet<String>, | |||
tmp_state: HashMap<String, Option<(DynStoreType, StoreTypeSer)>>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd just reuse pending_state
, the only difference is that for tmp values you do not update modified_keys
.
You can also implement that with existing get
/set
methods by adding flag
@@ -42,6 +52,11 @@ impl PureInterpreter for Dup { | |||
} | |||
// TODO: check if copyable |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Invite you to implement this as well :)
amount.value().into(), | ||
)?; | ||
|
||
stack.push(StackItem::Option(OptionItem::Some(Box::new(ticket.into())))) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is OptionItem::some()
identifier: &Micheline, | ||
identifier_ty: &Type, | ||
owner: &Address, | ||
) -> Result<UBig>; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suggest using Nat/Int on the interface level so that if we swap the underlying big number library, we don't have to change anything here
} | ||
|
||
#[derive(Clone, Debug)] | ||
pub struct TicketBalanceDiff { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe reuse naming from Tezos codebase "TicketUpdate" ?
No description provided.