diff --git a/src/proto_alpha/lib_protocol/src/baking.mli b/src/proto_alpha/lib_protocol/src/baking.mli index 2a7f25510..9d590ad51 100644 --- a/src/proto_alpha/lib_protocol/src/baking.mli +++ b/src/proto_alpha/lib_protocol/src/baking.mli @@ -45,7 +45,7 @@ val check_endorsement_rights: context -> Kind.endorsement Operation.t -> (public_key_hash * int list * bool) tzresult Lwt.t -(** Returns the endorsement reward calculated w.r.t a given priotiry. *) +(** Returns the endorsement reward calculated w.r.t a given priority. *) val endorsement_reward: context -> block_priority:int -> int -> Tez.t tzresult Lwt.t (** [baking_priorities ctxt level] is the lazy list of contract's diff --git a/src/proto_alpha/lib_protocol/src/delegate_storage.ml b/src/proto_alpha/lib_protocol/src/delegate_storage.ml index 0eed840e6..3c69d5971 100644 --- a/src/proto_alpha/lib_protocol/src/delegate_storage.ml +++ b/src/proto_alpha/lib_protocol/src/delegate_storage.ml @@ -376,7 +376,7 @@ let punish ctxt delegate cycle = get_frozen_rewards ctxt contract cycle >>=? fun rewards -> Roll_storage.Delegate.remove_amount ctxt delegate deposit >>=? fun ctxt -> Roll_storage.Delegate.remove_amount ctxt delegate fees >>=? fun ctxt -> - (* Rewards are not in the delegate balance yet... *) + (* Rewards are not accounted in the delegate's rolls yet... *) Storage.Contract.Frozen_deposits.remove (ctxt, contract) cycle >>= fun ctxt -> Storage.Contract.Frozen_fees.remove (ctxt, contract) cycle >>= fun ctxt -> Storage.Contract.Frozen_rewards.remove (ctxt, contract) cycle >>= fun ctxt -> diff --git a/src/proto_alpha/lib_protocol/src/raw_context.mli b/src/proto_alpha/lib_protocol/src/raw_context.mli index 793afe174..0e7f065cd 100644 --- a/src/proto_alpha/lib_protocol/src/raw_context.mli +++ b/src/proto_alpha/lib_protocol/src/raw_context.mli @@ -69,8 +69,16 @@ val patch_constants: context Lwt.t val first_level: context -> Raw_level_repr.t +(** Increment the current block fee stash that will be credited to baker's + frozen_fees account at finalize_application *) val add_fees: context -> Tez_repr.t -> context tzresult Lwt.t + +(** Increment the current block reward stash that will be credited to baker's + frozen_fees account at finalize_application *) val add_rewards: context -> Tez_repr.t -> context tzresult Lwt.t + +(** Increment the current block deposit stash for a specific delegate. All the + delegates' frozen_deposit accounts are credited at finalize_application *) val add_deposit: context -> Signature.Public_key_hash.t -> Tez_repr.t -> context tzresult Lwt.t