From: Matthew Wilcox <willy@infradead.org>
To: SeongJae Park <sj@kernel.org>
Cc: "Liam R. Howlett" <liam@infradead.org>,
Alice Ryhl <aliceryhl@google.com>,
Steven Rostedt <rostedt@goodmis.org>,
LKML <linux-kernel@vger.kernel.org>,
linux-mm@kvack.org, Andrew Ballance <andrewjballance@gmail.com>,
maple-tree@lists.infradead.org,
Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [PATCH] maple_tree: document that "last" in mtree_insert_range() is inclusive
Date: Sat, 9 May 2026 09:31:13 +0100 [thread overview]
Message-ID: <af7w0Zly7Se5my_c@casper.infradead.org> (raw)
In-Reply-To: <20260509005947.84550-1-sj@kernel.org>
On Fri, May 08, 2026 at 05:59:46PM -0700, SeongJae Park wrote:
> > > * @first: The start of the range
> > > * @last: The end of the range (inclusive)
> >
> >
> > I like this.
>
> +1. I'm also wondering if it make sense to add '(inclusive)' for 'first', too.
I can't think of a situation in computing where we use an
exclusive-first. Pure mathematics, yes, we might want to express a
range as (1,2) to exclude both 1 and 2 but include 1+epsilon for all
epsilon > 0. Maybe I don't work with floating point numbers enough,
but I've never seen a kernel programmer make an off-by-one with the
start of a range. End-of-the-range is all too common.
next prev parent reply other threads:[~2026-05-09 8:31 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-06 14:52 [PATCH] maple_tree: document that "last" in mtree_insert_range() is inclusive Steven Rostedt
2026-05-07 6:44 ` Alice Ryhl
2026-05-08 20:51 ` Liam R. Howlett
2026-05-09 0:59 ` SeongJae Park
2026-05-09 8:31 ` Matthew Wilcox [this message]
2026-05-09 15:38 ` SeongJae Park
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=af7w0Zly7Se5my_c@casper.infradead.org \
--to=willy@infradead.org \
--cc=akpm@linux-foundation.org \
--cc=aliceryhl@google.com \
--cc=andrewjballance@gmail.com \
--cc=liam@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=maple-tree@lists.infradead.org \
--cc=rostedt@goodmis.org \
--cc=sj@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox