This commit is contained in:
Ursulafe 2023-12-13 08:30:10 +00:00
parent 94c91cc6d8
commit 967ceca76e

View file

@ -47,7 +47,7 @@ type Options struct {
}
// Estimate returns the lowest possible gas limit that allows the transaction to
// run successfully with the provided context optons. It returns an error if the
// run successfully with the provided context options. It returns an error if the
// transaction would always revert, or if there are unexpected failures.
func Estimate(ctx context.Context, call *core.Message, opts *Options, gasCap uint64) (uint64, []byte, error) {
// Binary search the gas limit, as it may need to be higher than the amount used