summaryrefslogtreecommitdiff
path: root/Source/JavaScriptCore/runtime/DateConstructor.h
diff options
context:
space:
mode:
authorLorry Tar Creator <lorry-tar-importer@lorry>2017-06-27 06:07:23 +0000
committerLorry Tar Creator <lorry-tar-importer@lorry>2017-06-27 06:07:23 +0000
commit1bf1084f2b10c3b47fd1a588d85d21ed0eb41d0c (patch)
tree46dcd36c86e7fbc6e5df36deb463b33e9967a6f7 /Source/JavaScriptCore/runtime/DateConstructor.h
parent32761a6cee1d0dee366b885b7b9c777e67885688 (diff)
downloadWebKitGtk-tarball-master.tar.gz
Diffstat (limited to 'Source/JavaScriptCore/runtime/DateConstructor.h')
-rw-r--r--Source/JavaScriptCore/runtime/DateConstructor.h58
1 files changed, 28 insertions, 30 deletions
diff --git a/Source/JavaScriptCore/runtime/DateConstructor.h b/Source/JavaScriptCore/runtime/DateConstructor.h
index 383e6f1b3..fcea55f8d 100644
--- a/Source/JavaScriptCore/runtime/DateConstructor.h
+++ b/Source/JavaScriptCore/runtime/DateConstructor.h
@@ -1,6 +1,6 @@
/*
* Copyright (C) 1999-2000 Harri Porten (porten@kde.org)
- * Copyright (C) 2008, 2011 Apple Inc. All rights reserved.
+ * Copyright (C) 2008, 2011, 2016 Apple Inc. All rights reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -18,47 +18,45 @@
*
*/
-#ifndef DateConstructor_h
-#define DateConstructor_h
+#pragma once
#include "InternalFunction.h"
namespace JSC {
- class DatePrototype;
+class DatePrototype;
+class GetterSetter;
- class DateConstructor : public InternalFunction {
- public:
- typedef InternalFunction Base;
+class DateConstructor : public InternalFunction {
+public:
+ typedef InternalFunction Base;
+ static const unsigned StructureFlags = Base::StructureFlags | HasStaticPropertyTable;
- static DateConstructor* create(VM& vm, Structure* structure, DatePrototype* datePrototype)
- {
- DateConstructor* constructor = new (NotNull, allocateCell<DateConstructor>(vm.heap)) DateConstructor(vm, structure);
- constructor->finishCreation(vm, datePrototype);
- return constructor;
- }
+ static DateConstructor* create(VM& vm, Structure* structure, DatePrototype* datePrototype, GetterSetter*)
+ {
+ DateConstructor* constructor = new (NotNull, allocateCell<DateConstructor>(vm.heap)) DateConstructor(vm, structure);
+ constructor->finishCreation(vm, datePrototype);
+ return constructor;
+ }
- DECLARE_INFO;
+ DECLARE_INFO;
- static Structure* createStructure(VM& vm, JSGlobalObject* globalObject, JSValue prototype)
- {
- return Structure::create(vm, globalObject, prototype, TypeInfo(ObjectType, StructureFlags), info());
- }
+ static Structure* createStructure(VM& vm, JSGlobalObject* globalObject, JSValue prototype)
+ {
+ return Structure::create(vm, globalObject, prototype, TypeInfo(ObjectType, StructureFlags), info());
+ }
- protected:
- void finishCreation(VM&, DatePrototype*);
- static const unsigned StructureFlags = OverridesGetOwnPropertySlot | InternalFunction::StructureFlags;
+protected:
+ void finishCreation(VM&, DatePrototype*);
- private:
- DateConstructor(VM&, Structure*);
- static ConstructType getConstructData(JSCell*, ConstructData&);
- static CallType getCallData(JSCell*, CallData&);
+private:
+ DateConstructor(VM&, Structure*);
+ static ConstructType getConstructData(JSCell*, ConstructData&);
+ static CallType getCallData(JSCell*, CallData&);
+};
- static bool getOwnPropertySlot(JSObject*, ExecState*, PropertyName, PropertySlot&);
- };
+JSObject* constructDate(ExecState*, JSGlobalObject*, JSValue newTarget, const ArgList&);
- JSObject* constructDate(ExecState*, JSGlobalObject*, const ArgList&);
+EncodedJSValue JSC_HOST_CALL dateNow(ExecState*);
} // namespace JSC
-
-#endif // DateConstructor_h