Skip to content

Commit

Permalink
[Truffle] Add Fixnum specializations to untaint
Browse files Browse the repository at this point in the history
  • Loading branch information
Brandon Fish committed Oct 9, 2016
1 parent 1393288 commit 3b07686
Showing 1 changed file with 10 additions and 0 deletions.
Expand Up @@ -1886,6 +1886,16 @@ public UntaintNode(RubyContext context, SourceSection sourceSection) {
writeTaintNode = WriteObjectFieldNodeGen.create(Layouts.TAINTED_IDENTIFIER);
}

@Specialization
public int untaint(int num) {
return num;
}

@Specialization
public long untaint(long num) {
return num;
}

@Specialization
public Object taint(DynamicObject object) {
if (!isTaintedNode.executeIsTainted(object)) {
Expand Down

0 comments on commit 3b07686

Please sign in to comment.