On Sun, 23 Apr 2017, Oleg Nesterov wrote:

> On 04/22, Julia Lawall wrote:
> >
> > On Sat, 22 Apr 2017, Oleg Nesterov wrote:
> >
> > > It looks as if only one pattern from disjunction can match in the same 
> > > statement.
> > > IOW, (PAT1 | PAT2) actually means (PAT1* | PAT2*), not (PAT1 | PAT2)*. 
> > > Say,
> > >
> > The idea with a disjunction is that if the first rule matches, then that
> > one wins.  Actually, ( A | B ) is encoded as A v (not A & B).
>
> OK, thanks a lot Julia!
>
> Does this mean that I have to write 2 separate rules if I want to track the 
> member
> dereferences? One for "->" and another for ".", because I can't use the 
> "operator"
> metadecl in this case.

This would be safer in any case.

julia
_______________________________________________
Cocci mailing list
[email protected]
https://systeme.lip6.fr/mailman/listinfo/cocci

Reply via email to