mirror of
https://github.com/servo/servo.git
synced 2025-07-23 07:13:52 +01:00
codegen: throw type error when encountering an unknown argument
This commit is contained in:
parent
39bd45529d
commit
5149aefd85
2 changed files with 7 additions and 2 deletions
|
@ -492,7 +492,7 @@ class CGMethodCall(CGThing):
|
|||
else:
|
||||
# Just throw; we have no idea what we're supposed to
|
||||
# do with this.
|
||||
caseBody.append(CGGeneric("throw_internal_error(*cx, \"Could not convert JavaScript argument\");\n"
|
||||
caseBody.append(CGGeneric("throw_type_error(*cx, \"Could not convert JavaScript argument\");\n"
|
||||
"return false;"))
|
||||
|
||||
argCountCases.append(CGCase(str(argCount),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue