Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-25 Thread Markus Armbruster
John Snow writes: > On 3/25/21 2:18 AM, Markus Armbruster wrote: [...] >> Apropos qapi-gen testing scripts. I have scripts to show me how the >> generated code changes along the way in a branch. They evolved over a >> long time, and try to cope with changes in the tree that are hardly >>

Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-25 Thread John Snow
On 3/25/21 2:18 AM, Markus Armbruster wrote: John Snow writes: On 3/24/21 1:57 AM, Markus Armbruster wrote: John Snow writes: On 3/23/21 5:40 AM, Markus Armbruster wrote: Naming rules differ for the various kinds of names. To prepare enforcing them, define functions to check them:

Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-25 Thread Markus Armbruster
John Snow writes: > On 3/24/21 1:57 AM, Markus Armbruster wrote: >> John Snow writes: >> >>> On 3/23/21 5:40 AM, Markus Armbruster wrote: Naming rules differ for the various kinds of names. To prepare enforcing them, define functions to check them: check_name_upper(),

Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-24 Thread John Snow
On 3/24/21 1:57 AM, Markus Armbruster wrote: John Snow writes: On 3/23/21 5:40 AM, Markus Armbruster wrote: Naming rules differ for the various kinds of names. To prepare enforcing them, define functions to check them: check_name_upper(), check_name_lower(), and check_name_camel(). For

Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-23 Thread Markus Armbruster
John Snow writes: > On 3/23/21 5:40 AM, Markus Armbruster wrote: >> Naming rules differ for the various kinds of names. To prepare >> enforcing them, define functions to check them: check_name_upper(), >> check_name_lower(), and check_name_camel(). For now, these merely >> wrap around

Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-23 Thread John Snow
On 3/23/21 5:40 AM, Markus Armbruster wrote: Naming rules differ for the various kinds of names. To prepare enforcing them, define functions to check them: check_name_upper(), check_name_lower(), and check_name_camel(). For now, these merely wrap around check_name_str(), but that will change

Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-23 Thread Markus Armbruster
Markus Armbruster writes: > Eric Blake writes: > >> On 3/23/21 4:40 AM, Markus Armbruster wrote: >>> Naming rules differ for the various kinds of names. To prepare >>> enforcing them, define functions to check them: check_name_upper(), >>> check_name_lower(), and check_name_camel(). For now,

Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-23 Thread Markus Armbruster
Eric Blake writes: > On 3/23/21 4:40 AM, Markus Armbruster wrote: >> Naming rules differ for the various kinds of names. To prepare >> enforcing them, define functions to check them: check_name_upper(), >> check_name_lower(), and check_name_camel(). For now, these merely >> wrap around

Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-23 Thread John Snow
On 3/23/21 10:20 AM, Eric Blake wrote: -valid_name = re.compile(r'^(__[a-zA-Z0-9.-]+_)?' -'[a-zA-Z][a-zA-Z0-9_-]*$') I'm assuming python concatenates r'' with '' in the obvious manner... FWIW, I don't think it does, actually. I believe you do need to spell out each

Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-23 Thread Eric Blake
On 3/23/21 9:30 AM, John Snow wrote: > On 3/23/21 10:20 AM, Eric Blake wrote: >>> -valid_name = re.compile(r'^(__[a-zA-Z0-9.-]+_)?' >>> -    '[a-zA-Z][a-zA-Z0-9_-]*$') >> I'm assuming python concatenates r'' with '' in the obvious manner... >> > > FWIW, I don't think it does,

Re: [PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-23 Thread Eric Blake
On 3/23/21 4:40 AM, Markus Armbruster wrote: > Naming rules differ for the various kinds of names. To prepare > enforcing them, define functions to check them: check_name_upper(), > check_name_lower(), and check_name_camel(). For now, these merely > wrap around check_name_str(), but that will

[PATCH 10/28] qapi: Rework name checking in preparation of stricter checking

2021-03-23 Thread Markus Armbruster
Naming rules differ for the various kinds of names. To prepare enforcing them, define functions to check them: check_name_upper(), check_name_lower(), and check_name_camel(). For now, these merely wrap around check_name_str(), but that will change shortly. Replace the other uses of