diff -r e350771c23a3 -r 013f81b729de server/rqlannotation.py --- a/server/rqlannotation.py Mon Feb 07 18:19:40 2011 +0100 +++ b/server/rqlannotation.py Tue Feb 08 12:23:30 2011 +0100 @@ -195,7 +195,7 @@ for rel in sorted(relations, key=lambda x: (x.children[0].name, x.r_type)): # only equality relation with a variable as rhs may be principal if rel.operator() not in ('=', 'IS') \ - or not isinstance(rel.children[1].children[0], VariableRef): + or not isinstance(rel.children[1].children[0], VariableRef) or rel.neged(strict=True): continue if rel.scope is rel.stmt: return rel