Skip to content

Commit

Permalink
[truffle] Add @OverRide annotations
Browse files Browse the repository at this point in the history
  • Loading branch information
pmurias committed Jun 28, 2018
1 parent e9c533a commit 47b04cd
Show file tree
Hide file tree
Showing 9 changed files with 9 additions and 0 deletions.
Expand Up @@ -15,6 +15,7 @@ public NQPConcatNode(NQPNode leftNode, NQPNode rightNode) {
this.rightNode = rightNode;
}

@Override
public String executeStr(VirtualFrame frame) {
return leftNode.executeStr(frame) + rightNode.executeStr(frame);
}
Expand Down
Expand Up @@ -52,6 +52,7 @@ public NQPIValNode(long value) {
this.value = value;
}

@Override
public long executeInt(VirtualFrame frame) {
return value;
}
Expand Down
Expand Up @@ -13,6 +13,7 @@ public NQPLcNode(NQPNode aNode) {
this.argNode = argNode;
}

@Override
public String executeStr(VirtualFrame frame) {
return argNode.executeStr(frame).toLowerCase();
}
Expand Down
Expand Up @@ -52,6 +52,7 @@ public NQPNValNode(double value) {
this.value = value;
}

@Override
public double executeNum(VirtualFrame frame) {
return value;
}
Expand Down
Expand Up @@ -48,6 +48,7 @@

@NodeInfo(shortName = "null")
public final class NQPNullNode extends NQPNode {
@Override
public Object execute(VirtualFrame frame) {
return NQPNull.SINGLETON;
}
Expand Down
Expand Up @@ -52,6 +52,7 @@ public NQPSValNode(String value) {
this.value = value;
}

@Override
public String executeStr(VirtualFrame frame) {
return value;
}
Expand Down
Expand Up @@ -13,6 +13,7 @@ public NQPUcNode(NQPNode aNode) {
this.argNode = argNode;
}

@Override
public String executeStr(VirtualFrame frame) {
return argNode.executeStr(frame).toUpperCase();
}
Expand Down
Expand Up @@ -58,6 +58,7 @@ public NQPGetPositionalNode(FrameSlot slot, int index) {
this.index = index;
}

@Override
public Object execute(VirtualFrame frame) {
Object[] args = frame.getArguments();
Object value = args[index];
Expand Down
Expand Up @@ -59,6 +59,7 @@ public NQPReadLocalVariableNode(FrameSlot slot) {
this.slot = slot;
}

@Override
public Object execute(VirtualFrame frame) {
return FrameUtil.getObjectSafe(frame, slot);
}
Expand Down

0 comments on commit 47b04cd

Please sign in to comment.