From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS53758 23.128.96.0/24 X-Spam-Status: No, score=-3.9 required=3.0 tests=AWL,BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by dcvr.yhbt.net (Postfix) with ESMTP id 6D21F1F8C6 for ; Sun, 12 Sep 2021 22:43:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236602AbhILWod (ORCPT ); Sun, 12 Sep 2021 18:44:33 -0400 Received: from cloud.peff.net ([104.130.231.41]:45738 "EHLO cloud.peff.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236565AbhILWoc (ORCPT ); Sun, 12 Sep 2021 18:44:32 -0400 Received: (qmail 17099 invoked by uid 109); 12 Sep 2021 22:43:17 -0000 Received: from Unknown (HELO peff.net) (10.0.1.2) by cloud.peff.net (qpsmtpd/0.94) with ESMTP; Sun, 12 Sep 2021 22:43:17 +0000 Authentication-Results: cloud.peff.net; auth=none Received: (qmail 3002 invoked by uid 111); 12 Sep 2021 22:43:16 -0000 Received: from coredump.intra.peff.net (HELO sigill.intra.peff.net) (10.0.0.2) by peff.net (qpsmtpd/0.94) with (TLS_AES_256_GCM_SHA384 encrypted) ESMTPS; Sun, 12 Sep 2021 18:43:16 -0400 Authentication-Results: peff.net; auth=none Date: Sun, 12 Sep 2021 18:43:16 -0400 From: Jeff King To: =?utf-8?B?w4Z2YXIgQXJuZmrDtnLDsA==?= Bjarmason Cc: git@vger.kernel.org, Junio C Hamano , Johannes Schindelin Subject: Re: [PATCH 2/2] parse-options API: remove OPTION_ARGUMENT feature Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org On Sat, Sep 11, 2021 at 08:21:12PM +0200, Ævar Arnfjörð Bjarmason wrote: > As was noted in 1a85b49b87a (parse-options: make OPT_ARGUMENT() more > useful, 2019-03-14) there's only ever been one user of the > OPT_ARGUMENT(), that user was added in 20de316e334 (difftool: allow > running outside Git worktrees with --no-index, 2019-03-14). > > The OPT_ARGUMENT() feature itself was added way back in > 580d5bffdea (parse-options: new option type to treat an option-like > parameter as an argument., 2008-03-02), but as discussed in > 1a85b49b87a wasn't used until 20de316e334 in 2019. > > Now that the preceding commit has migrated this code over to using > "struct strvec" to manage the "args" member of a "struct > child_process", we can just use that directly instead of relying on > OPT_ARGUMENT. Yeah, the change in difftool here looks fine (regardless of how the cleanup in the first patch gets there). And I'm happy to see this somewhat weird OPT_ macro go away if nobody is using it. -Peff