D7787: rust-nodemap: building blocks for nodetree structures

martinvonz (Martin von Zweigbergk) phabricator at mercurial-scm.org
Tue Jan 21 13:02:06 EST 2020


martinvonz added a comment.


  Just a few nits here, but it looks like we're expecting an update on this series anyway, so maybe you can address them.

INLINE COMMENTS

> nodemap.rs:8
> +//!
> +//! This provides a variation on the radix tree with valency 16 that is
> +//! provided as "nodetree" in revlog.c, ready for append-only persistence

i think s/valency/arity/ is a more common term for it

> nodemap.rs:36
> +impl From<RawElement> for Element {
> +    /// Conversion from low level representation, after endianity conversion.
> +    ///

s/endianity/endianness/ (same further down)

> nodemap.rs:96
> +
> +    fn set(&mut self, nybble: u8, elt: Element) {
> +        self.0[nybble as usize] = RawElement::to_be(elt.into())

Could you call it `element` instead? I think it's a little obvious what that means. `elt` is at least not an abbreviation I'm familiar with.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D7787/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D7787

To: gracinet, #hg-reviewers, kevincox
Cc: martinvonz, durin42, kevincox, mercurial-devel


More information about the Mercurial-devel mailing list