0
0
Fork 0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2024-11-22 02:15:12 +00:00

[swfinterp] Implement equals opcode

This commit is contained in:
Philipp Hagemeister 2014-11-17 04:27:51 +01:00
parent 3cbcff8a2d
commit eb5376044c
2 changed files with 15 additions and 0 deletions

View file

@ -0,0 +1,10 @@
// input: []
// output: false
package {
public class EqualsOperator {
public static function main():Boolean{
return 1 == 2;
}
}
}

View file

@ -629,6 +629,11 @@ def resfunc(args):
value1 = stack.pop()
res = value1 % value2
stack.append(res)
elif opcode == 171: # equals
value2 = stack.pop()
value1 = stack.pop()
result = value1 == value2
stack.append(result)
elif opcode == 175: # greaterequals
value2 = stack.pop()
value1 = stack.pop()