Bug 873647 - Teach codegen how to wrap Dates in constructors. r=bz

--HG--
extra : rebase_source : f4267f15b7076aacb47fb94e4173a05dac8de255
This commit is contained in:
Reuben Morais 2013-05-17 13:52:32 -07:00
Родитель a183814740
Коммит 2a3b57fffc
3 изменённых файлов: 6 добавлений и 1 удалений

Просмотреть файл

@ -4376,7 +4376,7 @@ def wrapTypeIntoCurrentCompartment(type, value, isMember=True):
"arguments yet")
if (type.isString() or type.isPrimitive() or type.isEnum() or
type.isGeckoInterface() or type.isCallback()):
type.isGeckoInterface() or type.isCallback() or type.isDate()):
# All of these don't need wrapping
return None

Просмотреть файл

@ -121,6 +121,10 @@ public:
static
already_AddRefed<TestInterface>
Constructor(const GlobalObject&, uint32_t, IndirectlyImplementedInterface&, ErrorResult&);
static
already_AddRefed<TestInterface>
Constructor(const GlobalObject&, Date&, ErrorResult&);
/* static
already_AddRefed<TestInterface>
Constructor(const GlobalObject&, uint32_t, uint32_t,

Просмотреть файл

@ -101,6 +101,7 @@ interface OnlyForUseInConstructor {
Constructor(unsigned long num, boolean? boolArg),
Constructor(TestInterface? iface),
Constructor(long arg1, IndirectlyImplementedInterface iface),
Constructor(Date arg1),
// Constructor(long arg1, long arg2, (TestInterface or OnlyForUseInConstructor) arg3),
NamedConstructor=Test,
NamedConstructor=Test(DOMString str),