private static Pointcut parsePointcut(String pointcutString, AjAttributeStruct struct, boolean allowIf) {
try {
PatternParser parser = new PatternParser(pointcutString, struct.context);
Pointcut pointcut = parser.parsePointcut();
parser.checkEof();
pointcut.check(null, struct.enclosingType.getWorld());
if (!allowIf && pointcutString.indexOf("if()") >= 0 && hasIf(pointcut)) {
reportError("if() pointcut is not allowed at this pointcut location '" + pointcutString + "'", struct);
return null;
}
pointcut.setLocation(struct.context, -1, -1);// FIXME -1,-1 is not