From: Oswald Buddenhagen Date: Tue, 19 Sep 2023 09:40:54 GMT Subject: Re: [PATCH 2/2] parse-options: use and require int pointer for OPT_CMDMODE Message-ID: In-Reply-To: On Sat, Sep 09, 2023 at 11:14:20PM +0200, René Scharfe wrote: >Some uses of OPT_CMDMODE provide a pointer to an enum. It is >dereferenced as an int pointer in parse-options.c::get_value(). These >two types are incompatible, though > s/are/may be/ - c.f. https://en.cppreference.com/w/c/language/enum >-- the storage size of an enum can vary between platforms. > here's a completely different perspective: this is merely a theoretical problem, right? gcc for example won't actually use non-ints unless -fshort-enums is supplied. so how about simply adding a (configure) test to ensure that there is actually no problem, and calling it a day? regards