On 2/16/19 7:33 AM, Markus Elfring wrote: >> There's a qualifier propagation issue left in the case the field is an array. >> I have attached a patch that extends the tests/qualifier.c test case >> to demonstrate the problem. > > Can the desired functionality check be performed also with a bit less > source code by using the conditional operator? Sure it can. Would it be better? No. Exercise left to the interested reader why I consider my variant to be better.
> > - return (int *)&b->i; > + return b->i ? (int *)&b->i : (int *)&b->j[0]; > > > Will both test approaches be eventually needed? bye michael _______________________________________________ Cocci mailing list Cocci@systeme.lip6.fr https://systeme.lip6.fr/mailman/listinfo/cocci