git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Microproject idea: new OPT_* macros for PARSE_OPT_NONEG

From
Duy Nguyen <pclouds@gmail.com>
Date
Mar 7, 2014, 07:54 UTC
Message-ID
<CACsJy8AUhHE8=Yaj6_G46V6w5ZbA3z403GkBfsbZL7MxgeA3RQ@mail.gmail.com>
In-Reply-To
<531977AF.4060907@alum.mit.edu>
On Fri, Mar 7, 2014 at 2:39 PM, Michael Haggerty <mhagger@alum.mit.edu> wrote:
Show 15 quoted lines
> On 03/07/2014 02:38 AM, Duy Nguyen wrote:
>> Currently in order to avoid --[no]-xxx form we have to resort to
>> declare full struct option. It'd be nice to have a set of OPT_* macros
>> with PARSE_OPT_NONEG set. Find and update all "struct option []"
>> declarations with the new macros (including ones that should never
>> accept --no- form, but do anyway).
>
> I added this to the list, with the following warning:
>
>     This is more a milliproject than a microproject
>
> because to me it feels considerably more involved than the other
> microprojects.  To  complete it, the student will have to understand at
> least part of the parse_options() API, which is more than a 15 minute
> job by itself.

I don't know the scope of these microprojects, but yes I think it'll take a few hours for this. By the way, a bit more thought on the idea: instead of making OPT_BOOL_NONEG() that sets NONEG, we could make OPT_BOOL_FLAGS(..., NONEG), which is more flexible.

-- 
Duy
Previous: Michael HaggertyNext: Junio C Hamano
Message 3 of 7 in “Microproject idea: new OPT_* macros for PARSE_OPT_NONEG”
  1. Duy NguyenMar 7, 2014
  2. Michael HaggertyMar 7, 2014
  3. Duy NguyenMar 7, 2014
  4. Junio C HamanoMar 7, 2014
  5. Duy NguyenMar 12, 2014
  6. Junio C HamanoMar 13, 2014
  7. Duy NguyenMar 13, 2014

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.