erlang-hbbft icon indicating copy to clipboard operation
erlang-hbbft copied to clipboard

Define internal accessors on module state structures

Open xandkar opened this issue 3 years ago • 0 comments

As per @vihu's original suggestion at https://github.com/helium/erlang-hbbft/pull/62#discussion_r585546569

We don't need to go too-crazy, since theses structures are not accessed from outside the module, hence we could score wins only in cases of common combinations, such as B/N (which first needs to extract both B and N from state record). Perhaps also in cases where pattern matching gets a little too noisy.

xandkar avatar Mar 04 '21 17:03 xandkar