summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--dom/bindings/Codegen.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/dom/bindings/Codegen.py b/dom/bindings/Codegen.py
index cb93e4897..5c4aa746d 100644
--- a/dom/bindings/Codegen.py
+++ b/dom/bindings/Codegen.py
@@ -4355,7 +4355,9 @@ def handleDefaultStringValue(defaultValue, method):
passing as the second argument of handleDefault; in particular it does not
end with a ';'
"""
- assert defaultValue.type.isDOMString() or defaultValue.type.isByteString()
+ assert (defaultValue.type.isDOMString() or
+ defaultValue.type.isUSVString() or
+ defaultValue.type.isByteString())
return ("static const %(char_t)s data[] = { %(data)s };\n"
"%(method)s(data, ArrayLength(data) - 1)") % {
'char_t': "char" if defaultValue.type.isByteString() else "char16_t",