/**
   * @return whether or not that was a change to the global signature XXX for efficiency we will
   *     need a richer representation than this
   */
  public boolean addOrReplaceAspect(ResolvedType aspectType, boolean inWeavingPhase) {
    trace.enter("addOrReplaceAspect", this, new Object[] {aspectType, new Boolean(inWeavingPhase)});

    boolean change = false;
    CrosscuttingMembers xcut = (CrosscuttingMembers) members.get(aspectType);
    if (xcut == null) {
      members.put(aspectType, aspectType.collectCrosscuttingMembers(inWeavingPhase));
      clearCaches();
      CflowPointcut.clearCaches(aspectType);
      change = true;
    } else {
      if (xcut.replaceWith(aspectType.collectCrosscuttingMembers(inWeavingPhase), inWeavingPhase)) {
        clearCaches();

        CflowPointcut.clearCaches(aspectType);
        change = true;
      } else {
        if (!AsmManager.getDefault().getHandleProvider().dependsOnLocation() && inWeavingPhase) {
          // bug 134541 - even though we haven't changed we may have updated the
          // sourcelocation for the shadowMunger which we need to pick up
          shadowMungers = null;
        }
        change = false;
      }
    }
    if (aspectType.isAbstract()) {
      // we might have sub-aspects that need to re-collect their crosscutting members from us
      boolean ancestorChange = addOrReplaceDescendantsOf(aspectType, inWeavingPhase);
      change = change || ancestorChange;
    }
    changedSinceLastReset = changedSinceLastReset || change;

    trace.exit("addOrReplaceAspect", change);
    return change;
  }
 public void addAdviceLikeDeclares(ResolvedType aspectType) {
   CrosscuttingMembers xcut = (CrosscuttingMembers) members.get(aspectType);
   xcut.addDeclares(aspectType.collectDeclares(true));
 }