mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-21 20:46:36 -05:00
[swfinterp] Improve undefined representation
This commit is contained in:
parent
fbf94a7815
commit
f48d3e9bbc
1 changed files with 5 additions and 0 deletions
|
@ -170,6 +170,10 @@ def __bool__(self):
|
|||
def __hash__(self):
|
||||
return 0
|
||||
|
||||
def __str__(self):
|
||||
return 'undefined'
|
||||
__repr__ = __str__
|
||||
|
||||
undefined = _Undefined()
|
||||
|
||||
|
||||
|
@ -686,6 +690,7 @@ def resfunc(args):
|
|||
res = _builtin_classes[mname]
|
||||
else:
|
||||
# Assume unitialized
|
||||
# TODO warn here
|
||||
res = undefined
|
||||
stack.append(res)
|
||||
elif opcode == 97: # setproperty
|
||||
|
|
Loading…
Reference in a new issue