pub fn reply_commit_with_gas(
gas_limit: u64,
value: u128,
) -> Result<MessageId, Error>Expand description
Same as reply_commit, but with an explicit gas limit.
§Examples
use gstd::{exec, msg};
#[unsafe(no_mangle)]
extern "C" fn handle() {
msg::reply_push(b"Hello, ").expect("Unable to push");
msg::reply_push(b", world!").expect("Unable to push");
msg::reply_commit_with_gas(exec::gas_available() / 2, 0).expect("Unable to commit");
}§See also
reply_pushfunction allows forming a reply message in parts.