Re: [Cocci] OpenLDAP debug statements

2017-08-31 Thread Julia Lawall
On Thu, 31 Aug 2017, Ondřej Kuzník wrote: > On Thu, Aug 31, 2017 at 06:01:07PM +0200, Julia Lawall wrote: > > On Thu, 31 Aug 2017, Ondřej Kuzník wrote: > >> On Thu, Aug 31, 2017 at 05:52:14PM +0200, Julia Lawall wrote: > >>> So you want to drop the braces if there is no comment and keep the

Re: [Cocci] OpenLDAP debug statements

2017-08-31 Thread Julia Lawall
On Thu, 31 Aug 2017, Ondřej Kuzník wrote: > On Thu, Aug 31, 2017 at 04:09:30PM +0200, Julia Lawall wrote: > > The problem is in the rule shortcut_replace. You have: > > > > [...] > > > > There are three case (1, 2, and 3). Normally a disjunction like this > > matches from top to bottom, ie if

Re: [Cocci] OpenLDAP debug statements

2017-08-31 Thread Ondřej Kuzník
On Thu, Aug 31, 2017 at 04:09:30PM +0200, Julia Lawall wrote: > The problem is in the rule shortcut_replace. You have: > > [...] > > There are three case (1, 2, and 3). Normally a disjunction like this > matches from top to bottom, ie if the first case matches the ohers are not > considered.

Re: [Cocci] OpenLDAP debug statements

2017-08-31 Thread Julia Lawall
The problem is in the rule shortcut_replace. You have: ( -{ -\( T buf = {...}; \| T buf = I; \| T buf; \| \) -snprintf@p1( buf, E, format1, args ); -Debug@p2( L, format2, args_before, buf, args_after ); +Debug( L, merged, args_before, args, args_after ); -} | { -\( T buf = {...}; \| T buf = I;

Re: [Cocci] OpenLDAP debug statements

2017-08-31 Thread Ondřej Kuzník
On Wed, Aug 30, 2017 at 03:05:04PM +0200, Julia Lawall wrote: > On Wed, 30 Aug 2017, Ondřej Kuzník wrote: >> OK, I understand. I any case, the suggestion below has very few false >> negatives and no false positives that I could find, thanks a lot! >> >> The only false negatives are related to

Re: [Cocci] OpenLDAP debug statements

2017-08-30 Thread Julia Lawall
On Wed, 30 Aug 2017, Ondřej Kuzník wrote: > On Wed, Aug 30, 2017 at 07:25:00AM +0200, Julia Lawall wrote: > > On Tue, 29 Aug 2017, Ondřej Kuzník wrote: > >> On Tue, Aug 29, 2017 at 11:17:53PM +0200, Julia Lawall wrote: > >>> Allowing format list to match strings in multiple pieces seems like a

Re: [Cocci] OpenLDAP debug statements

2017-08-30 Thread Ondřej Kuzník
On Wed, Aug 30, 2017 at 07:25:00AM +0200, Julia Lawall wrote: > On Tue, 29 Aug 2017, Ondřej Kuzník wrote: >> On Tue, Aug 29, 2017 at 11:17:53PM +0200, Julia Lawall wrote: >>> Allowing format list to match strings in multiple pieces seems like a >>> somewhat complex undertaking. >> >> Again, I have

Re: [Cocci] OpenLDAP debug statements

2017-08-29 Thread Julia Lawall
On Tue, 29 Aug 2017, Ondřej Kuzník wrote: > On Tue, Aug 29, 2017 at 11:17:53PM +0200, Julia Lawall wrote: > > On Tue, 29 Aug 2017, Ondřej Kuzník wrote: > >> Hi again, > >> having achieved some consensus to go ahead with this in the project and > >> some time to spare again, I have started on

Re: [Cocci] OpenLDAP debug statements

2017-08-29 Thread Ondřej Kuzník
On Tue, Aug 29, 2017 at 11:17:53PM +0200, Julia Lawall wrote: > On Tue, 29 Aug 2017, Ondřej Kuzník wrote: >> Hi again, >> having achieved some consensus to go ahead with this in the project and >> some time to spare again, I have started on refining the patch to get as >> large >> part of the

Re: [Cocci] OpenLDAP debug statements

2017-08-29 Thread Julia Lawall
On Tue, 29 Aug 2017, Ondřej Kuzník wrote: > Hi again, > having achieved some consensus to go ahead with this in the project and > some time to spare again, I have started on refining the patch to get as large > part of the OpenLDAP source code converted as possible. > > There seem to be a few

Re: [Cocci] OpenLDAP debug statements

2017-08-29 Thread Julia Lawall
On Tue, 29 Aug 2017, Ondřej Kuzník wrote: > Hi again, > having achieved some consensus to go ahead with this in the project and > some time to spare again, I have started on refining the patch to get as large > part of the OpenLDAP source code converted as possible. > > There seem to be a few