Program: 68256
Project: 68256
Buggy source:
private MenuManager createMenuManager(final Object data){
  MenuManager menuManager=new MenuManager();
  menuManager.setRemoveAllWhenShown(true);
  menuManager.addMenuListener(new IMenuListener(){
    public void menuAboutToShow(    IMenuManager manager){
      if (data instanceof ColumnBindingInfo) {
        addMenu(manager,new HeaderShowAction(((ColumnBindingInfo)data).getName()));
        List<Object> actions=getActionsForTableHead(((ColumnBindingInfo)data).getName());
        for (        Object act : actions) {
          addMenu(manager,act);
        }
      }
 else       if (data instanceof Integer) {
        addMenu(manager,new HeaderShowAction(tablePreview.getCurrentColumnHeading()));
        String expr=ExpressionUtil.createJSRowExpression(tablePreview.getCurrentColumnHeading());
        List<Object> actions=getActionsForTableHead(expr);
        for (        Object act : actions) {
          addMenu(manager,act);
        }
      }
 else       if (data instanceof MeasureHandle) {
        String expr=createCubeExpression();
        if (expr != null) {
          addMenu(manager,getMenuForMeasure(getChartModel(),expr));
        }
      }
 else       if (data instanceof LevelHandle) {
        String expr=createCubeExpression();
        if (expr != null) {
          addMenu(manager,getMenuForDimension(getChartModel(),expr));
        }
      }
    }
    private void addMenu(    IMenuManager manager,    Object item){
      if (item instanceof IAction) {
        manager.add((IAction)item);
      }
 else       if (item instanceof IContributionItem) {
        manager.add((IContributionItem)item);
      }
 else       if (item instanceof List<?>) {
        for (        Object o : (List<?>)item) {
          addMenu(manager,o);
        }
      }
      if (getDataServiceProvider().isPartChart()) {
        if (item instanceof IAction) {
          ((IAction)item).setEnabled(false);
        }
      }
    }
  }
);
  return menuManager;
}

Fixed version (ground truth):
private MenuManager createMenuManager(final Object data){
  MenuManager menuManager=new MenuManager();
  menuManager.setRemoveAllWhenShown(true);
  menuManager.addMenuListener(new IMenuListener(){
    public void menuAboutToShow(    IMenuManager manager){
      if (data instanceof ColumnBindingInfo) {
        addMenu(manager,new HeaderShowAction(((ColumnBindingInfo)data).getName()));
        List<Object> actions=getActionsForTableHead(((ColumnBindingInfo)data).getName());
        for (        Object act : actions) {
          addMenu(manager,act);
        }
      }
 else       if (data instanceof Integer) {
        addMenu(manager,new HeaderShowAction(tablePreview.getCurrentColumnHeading()));
        String expr=tablePreview.getCurrentColumnHeading();
        List<Object> actions=getActionsForTableHead(expr);
        for (        Object act : actions) {
          addMenu(manager,act);
        }
      }
 else       if (data instanceof MeasureHandle) {
        String expr=createCubeExpression();
        if (expr != null) {
          addMenu(manager,getMenuForMeasure(getChartModel(),expr));
        }
      }
 else       if (data instanceof LevelHandle) {
        String expr=createCubeExpression();
        if (expr != null) {
          addMenu(manager,getMenuForDimension(getChartModel(),expr));
        }
      }
    }
    private void addMenu(    IMenuManager manager,    Object item){
      if (item instanceof IAction) {
        manager.add((IAction)item);
      }
 else       if (item instanceof IContributionItem) {
        manager.add((IContributionItem)item);
      }
 else       if (item instanceof List<?>) {
        for (        Object o : (List<?>)item) {
          addMenu(manager,o);
        }
      }
      if (getDataServiceProvider().isPartChart()) {
        if (item instanceof IAction) {
          ((IAction)item).setEnabled(false);
        }
      }
    }
  }
);
  return menuManager;
}