Received: from eggs.gnu.org ([2001:4830:134:3::10]:56073) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zwprb-0007yh-TS for qemu-devel@nongnu.org; Thu, 12 Nov 2015 06:16:24 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zwpra-0000YW-VQ for qemu-devel@nongnu.org; Thu, 12 Nov 2015 06:16:23 -0500 From: Markus Armbruster References: <1447224690-9743-1-git-send-email-eblake@redhat.com> <1447224690-9743-20-git-send-email-eblake@redhat.com> <87egfwbnfc.fsf@blackfin.pond.sub.org> <564366CB.6000804@redhat.com> <87mvuk5uli.fsf@blackfin.pond.sub.org> <1447317256.1400.26.camel@redhat.com> Date: Thu, 12 Nov 2015 12:16:12 +0100 In-Reply-To: <1447317256.1400.26.camel@redhat.com> (Gerd Hoffmann's message of "Thu, 12 Nov 2015 09:34:16 +0100") Message-ID: <87a8qjqxhf.fsf@blackfin.pond.sub.org> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] [PATCH v11 19/28] qapi: Change munging of CamelCase enum values List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Gerd Hoffmann Cc: Kevin Wolf , Peter Maydell , "open list:Block layer core" , "Michael S. Tsirkin" , Jason Wang , qemu-devel@nongnu.org, Michael Roth , Amit Shah , Luiz Capitulino , Andreas =?utf-8?Q?F=C3=A4rber?= Gerd Hoffmann writes: > Hi, > >> > If desired, I can prepare an alternate patch that adds the dash to the >> > qapi enum definition, to see what we think. >> >> If Gerd is fine with the rename, let's do it. > > No need to do so I think ... > >> >> - [INPUT_BUTTON_WHEEL_UP] = SDL_BUTTON(SDL_BUTTON_WHEELUP), >> >> - [INPUT_BUTTON_WHEEL_DOWN] = SDL_BUTTON(SDL_BUTTON_WHEELDOWN), >> >> + [INPUT_BUTTON_WHEELUP] = SDL_BUTTON(SDL_BUTTON_WHEELUP), >> >> + [INPUT_BUTTON_WHEELDOWN] = SDL_BUTTON(SDL_BUTTON_WHEELDOWN), >> > >> > Since SDL already spells the names without space, it's not the end of >> > the world if we do likewise. >> >> Good point. >> >> Even if we adopt SDL's spelling WHEELUP and WHEELDOWN, I'd still prefer >> to downcase the QAPI names for consistency with the rest of QAPI. > > This doesn't look too bad. And even if x-input-send-event isn't > official api I'd prefer to not break it for such a minor cosmetic issue. To slow our slide into a morass of inconsistency, I intend to make qapi.py enforce naming conventions. Involves a whitelist for existing violators we can't or won't fix. Naturally, I'd prefer to keep the list as short as possible. I feel these ones can and should be fixed, and the best time to fix them is when we drop the x- from the command. But if you insist on keeping the current names then, I'll live with the extra whitelist entries.