From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-il1-x132.google.com (mail-il1-x132.google.com [IPv6:2607:f8b0:4864:20::132]) by sourceware.org (Postfix) with ESMTPS id E53F93858D1E for ; Mon, 30 Jan 2023 14:30:04 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org E53F93858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=adacore.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=adacore.com Received: by mail-il1-x132.google.com with SMTP id u7so3634323ilg.4 for ; Mon, 30 Jan 2023 06:30:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=adacore.com; s=google; h=mime-version:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=hBDaGTFOxaxarB7kpdSaQW+z5nomt8+wrpZIep6iMA4=; b=RrTSJMbdA2b6STaC0vaUPm3cGHVcuafCdUrvhNCH8uj8GUkkef3wUOYCI+Xuc7BW6s JmvsQUWXetHNjO27t1AmY0L06EYOtoLvOjEte8BRIIB7qB27cz2IQxaCe+ZHlTKEVXaD 4iLN6XZLszeG/DUojWdKj0SpVhwGcR0Xbs03jrTotXsEIXIXZ3TYj+CTMWp3IRNKT6g3 fWvUaK/4crpyGq9QcrY4y7VKIB4m2maIcoS2AR5eQjLz8qeyYMZO6UtZzivLghATukB1 CATeqpeixdVpliLaT7WOK89kHtFoQWq0mvKZMXEQSd5BRaMuhFGBOVRrt0+MlbOw8Rzj mNrg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=hBDaGTFOxaxarB7kpdSaQW+z5nomt8+wrpZIep6iMA4=; b=7yFdSlgcOkAZYV93YB1EmIibRtrW2vZDKHN2ZE0OrJnGKm9Hrep25OF3K8ZzaZES2r 1h0pSP6dJiRQrxRjBietvUeCIlkESgRZvDFCkVmv4mD4efXzrLB9o+WAALQ+E9DB9t6I oLx21L2hnmXKoH+q/6oUDY/DFLZSQ55Pgx/hprRZEuNAQmX3O9vFJr4oGV+UIVpWex+X 6SOHzcDJmklioOxflz49wgGJFLYHmvmjoPPexdAySjx0wJj9J1EtisO8t2w8wlkk7/mr Ur8wjF5aX82prgr/rMG5dPStZ5wVNl6BABhjhsKF3njY8ChflM0HCoeSssZhbzb7xwb9 lZMw== X-Gm-Message-State: AO0yUKUgbG5+3X3ELbmMAxaUp54VR0/MbXFFZljglF4z8oyQQHGslltk c+FEinr2hkf2i5nHJ0tcioYgTmqme18P47FD X-Google-Smtp-Source: AK7set/TzNPfbVoQIa5bNLfT/IwHosrWgGQsxpO2IyjQvuTi3JsFQBBoM7MJeXOrlw6/WcJeloLUZw== X-Received: by 2002:a05:6e02:20c7:b0:310:ef5d:de9a with SMTP id 7-20020a056e0220c700b00310ef5dde9amr4109984ilq.24.1675089004165; Mon, 30 Jan 2023 06:30:04 -0800 (PST) Received: from murgatroyd (75-166-146-144.hlrn.qwest.net. [75.166.146.144]) by smtp.gmail.com with ESMTPSA id j3-20020a02cc63000000b003a5de29178esm4788465jaq.104.2023.01.30.06.30.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Jan 2023 06:30:03 -0800 (PST) From: Tom Tromey To: Simon Marchi Cc: Tom Tromey , gdb-patches@sourceware.org Subject: Re: [PATCH] Fix comparator bug in cooked index References: <20230127195632.1570281-1-tromey@adacore.com> <25a578ac-5036-832a-3577-8eb27996157f@simark.ca> X-Attribution: Tom Date: Mon, 30 Jan 2023 07:30:02 -0700 In-Reply-To: <25a578ac-5036-832a-3577-8eb27996157f@simark.ca> (Simon Marchi's message of "Fri, 27 Jan 2023 23:20:10 -0500") Message-ID: <87zga0nlhx.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-5.3 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: >>>>> "Simon" == Simon Marchi writes: >> + /* Comparison modes for the 'compare' function. See the function >> + for a description. */ >> + enum comparison_mode Simon> Just a nit, but I like to use enum class. For the simple reason that Simon> users do "comparison_mode::SORT" instead of just "SORT", and I find that Simon> this little bit of context helps when reading. I normally do too, but because it's in a class, this would lead to outside users having to write cooked_index_entry::comparison_mode::SORT which seemed excessively wordy. Tom