/** * Returns a deep clone of this {@link APlusNumericBinaryExpIR} node. * @return a deep clone of this {@link APlusNumericBinaryExpIR} node */ public APlusNumericBinaryExpIR clone() { return new APlusNumericBinaryExpIR( _sourceNode, _tag, _metaData, cloneNode(_type), cloneNode(_left), cloneNode(_right) ); }
/** * Called by the {@link APlusNumericBinaryExpIR} node from {@link APlusNumericBinaryExpIR#apply(IIsaAnalysis)}. * @param node the calling {@link APlusNumericBinaryExpIR} node */ public void caseAPlusNumericBinaryExpIR(APlusNumericBinaryExpIR node) throws AnalysisException { _visitedNodes.add(node); inAPlusNumericBinaryExpIR(node); if(node.getType() != null && !_visitedNodes.contains(node.getType())) { node.getType().apply(this); } if(node.getLeft() != null && !_visitedNodes.contains(node.getLeft())) { node.getLeft().apply(this); } if(node.getRight() != null && !_visitedNodes.contains(node.getRight())) { node.getRight().apply(this); } outAPlusNumericBinaryExpIR(node); }
/** * Essentially this.toString().equals(o.toString()). **/ @Override public boolean equals(Object o) { if (o != null && o instanceof APlusNumericBinaryExpIR) { return toString().equals(o.toString()); } return false; }
APlusNumericBinaryExpIR historyCounterSum = new APlusNumericBinaryExpIR(); historyCounterSum.setType(typeCg.clone()); historyCounterSum.setLeft(history); left.setOpsname(nextOpName); APlusNumericBinaryExpIR tmp = new APlusNumericBinaryExpIR(); tmp.setType(typeCg.clone()); tmp.setLeft(left); last.setRight(tmp); lastHistoryExp.setOpsname(lastOpName); last.setRight(lastHistoryExp);
+ concPrefixes.sentinelClassPostFix()); APlusNumericBinaryExpIR addedhistcounter = new APlusNumericBinaryExpIR(); firsthistcount.setType(new AIntNumericBasicTypeIR()); addedhistcounter.setLeft(firsthistcount); APlusNumericBinaryExpIR addition1 = new APlusNumericBinaryExpIR(); addition1 = addedhistcounter; histcountleft.setSentinelType(innerclass.clone()); APlusNumericBinaryExpIR addition = new APlusNumericBinaryExpIR(); addition.setLeft(histcountleft); addition1.setRight(addition); lastHistoryExpIR.setType(new AIntNumericBasicTypeIR()); lastHistoryExpIR.setSentinelType(innerclass.clone()); addition1.setRight(lastHistoryExpIR);
@Override public SExpIR caseAPlusNumericBinaryExp(APlusNumericBinaryExp node, IRInfo question) throws AnalysisException { return question.getExpAssistant().handleBinaryExp(node, new APlusNumericBinaryExpIR(), question); }
/** * Called by the {@link APlusNumericBinaryExpIR} node from {@link APlusNumericBinaryExpIR#apply(IAnalysis)}. * @param node the calling {@link APlusNumericBinaryExpIR} node */ public void caseAPlusNumericBinaryExpIR(APlusNumericBinaryExpIR node) throws AnalysisException { _visitedNodes.add(node); inAPlusNumericBinaryExpIR(node); if(node.getType() != null && !_visitedNodes.contains(node.getType())) { node.getType().apply(this); } if(node.getLeft() != null && !_visitedNodes.contains(node.getLeft())) { node.getLeft().apply(this); } if(node.getRight() != null && !_visitedNodes.contains(node.getRight())) { node.getRight().apply(this); } outAPlusNumericBinaryExpIR(node); }
/** * Creates a deep clone of this {@link APlusNumericBinaryExpIR} node while putting all * old node-new node relations in the map {@code oldToNewMap}. * @param oldToNewMap the map filled with the old node-new node relation * @return a deep clone of this {@link APlusNumericBinaryExpIR} node */ public APlusNumericBinaryExpIR clone(Map<INode,INode> oldToNewMap) { APlusNumericBinaryExpIR node = new APlusNumericBinaryExpIR( _sourceNode, _tag, _metaData, cloneNode(_type, oldToNewMap), cloneNode(_left, oldToNewMap), cloneNode(_right, oldToNewMap) ); oldToNewMap.put(this, node); return node; }
/** * Called by the {@link APlusNumericBinaryExpIR} node from {@link APlusNumericBinaryExpIR#apply(IAnalysis)}. * @param node the calling {@link APlusNumericBinaryExpIR} node */ public void caseAPlusNumericBinaryExpIR(APlusNumericBinaryExpIR node, Q question) throws AnalysisException { _visitedNodes.add(node); inAPlusNumericBinaryExpIR(node, question); if(node.getType() != null && !_visitedNodes.contains(node.getType())) { node.getType().apply(this, question); } if(node.getLeft() != null && !_visitedNodes.contains(node.getLeft())) { node.getLeft().apply(this, question); } if(node.getRight() != null && !_visitedNodes.contains(node.getRight())) { node.getRight().apply(this, question); } outAPlusNumericBinaryExpIR(node, question); }
/** * Called by the {@link APlusNumericBinaryExpIR} node from {@link APlusNumericBinaryExpIR#apply(IAnalysis)}. * @param node the calling {@link APlusNumericBinaryExpIR} node */ public A caseAPlusNumericBinaryExpIR(APlusNumericBinaryExpIR node, Q question) throws AnalysisException { _visitedNodes.add(node); A retVal = createNewReturnValue(node, question); mergeReturns(retVal,inAPlusNumericBinaryExpIR(node, question)); if(node.getType() != null && !_visitedNodes.contains(node.getType())) { mergeReturns(retVal,node.getType().apply(this, question)); } if(node.getLeft() != null && !_visitedNodes.contains(node.getLeft())) { mergeReturns(retVal,node.getLeft().apply(this, question)); } if(node.getRight() != null && !_visitedNodes.contains(node.getRight())) { mergeReturns(retVal,node.getRight().apply(this, question)); } mergeReturns(retVal,outAPlusNumericBinaryExpIR(node, question)); return retVal; }
/** * Called by the {@link APlusNumericBinaryExpIR} node from {@link APlusNumericBinaryExpIR#apply(IAnalysis)}. * @param node the calling {@link APlusNumericBinaryExpIR} node */ public A caseAPlusNumericBinaryExpIR(APlusNumericBinaryExpIR node) throws AnalysisException { _visitedNodes.add(node); A retVal = createNewReturnValue(node); mergeReturns(retVal,inAPlusNumericBinaryExpIR(node)); if(node.getType() != null && !_visitedNodes.contains(node.getType())) { mergeReturns(retVal,node.getType().apply(this)); } if(node.getLeft() != null && !_visitedNodes.contains(node.getLeft())) { mergeReturns(retVal,node.getLeft().apply(this)); } if(node.getRight() != null && !_visitedNodes.contains(node.getRight())) { mergeReturns(retVal,node.getRight().apply(this)); } mergeReturns(retVal,outAPlusNumericBinaryExpIR(node)); return retVal; }