Commit f0ea355f authored by weinig@apple.com's avatar weinig@apple.com

JavaScriptCore:

2008-06-30  Sam Weinig  <sam@webkit.org>

        Rubber-stamped by Darin Alder.

        Split InternalFunction into its own header file.

        * API/JSCallbackFunction.h:
        * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
        * JavaScriptCore.xcodeproj/project.pbxproj:
        * kjs/ArrayConstructor.h:
        * kjs/BooleanConstructor.h:
        * kjs/DateConstructor.h:
        * kjs/ErrorConstructor.h:
        * kjs/FunctionConstructor.h:
        * kjs/FunctionPrototype.h:
        * kjs/InternalFunction.h: Copied from kjs/JSFunction.h.
        * kjs/JSFunction.h:
        * kjs/NativeErrorConstructor.h:
        * kjs/NumberConstructor.h:
        * kjs/ObjectConstructor.h:
        * kjs/RegExpConstructor.h:
        * kjs/StringConstructor.h:
        * profiler/Profiler.cpp:

WebCore:

2008-06-30  Sam Weinig  <sam@webkit.org>

        Rubber-stamped by Darin Adler.

        Split InternalFunction into its own header file.

        * ForwardingHeaders/kjs/InternalFunction.h: Added.
        * bridge/runtime_method.h:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@34901 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 8e9caa38
......@@ -27,7 +27,7 @@
#ifndef JSCallbackFunction_h
#define JSCallbackFunction_h
#include "JSFunction.h"
#include "InternalFunction.h"
#include "JSObjectRef.h"
namespace KJS {
......
2008-06-30 Sam Weinig <sam@webkit.org>
Rubber-stamped by Darin Alder.
Split InternalFunction into its own header file.
* API/JSCallbackFunction.h:
* JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
* JavaScriptCore.xcodeproj/project.pbxproj:
* kjs/ArrayConstructor.h:
* kjs/BooleanConstructor.h:
* kjs/DateConstructor.h:
* kjs/ErrorConstructor.h:
* kjs/FunctionConstructor.h:
* kjs/FunctionPrototype.h:
* kjs/InternalFunction.h: Copied from kjs/JSFunction.h.
* kjs/JSFunction.h:
* kjs/NativeErrorConstructor.h:
* kjs/NumberConstructor.h:
* kjs/ObjectConstructor.h:
* kjs/RegExpConstructor.h:
* kjs/StringConstructor.h:
* profiler/Profiler.cpp:
2008-06-30 Sam Weinig <sam@webkit.org>
Reviewed by Kevin McCullough.
......@@ -452,6 +452,10 @@
RelativePath="..\..\kjs\InternalFunction.cpp"
>
</File>
<File
RelativePath="..\..\kjs\InternalFunction.h"
>
</File>
<File
RelativePath="..\..\kjs\interpreter.cpp"
>
......
......@@ -97,6 +97,7 @@
BC02E9130E1839DB000F9297 /* NativeErrorPrototype.h in Headers */ = {isa = PBXBuildFile; fileRef = BC02E90B0E1839DB000F9297 /* NativeErrorPrototype.h */; };
BC02E98D0E183E38000F9297 /* ErrorInstance.h in Headers */ = {isa = PBXBuildFile; fileRef = BC02E98B0E183E38000F9297 /* ErrorInstance.h */; };
BC1166020E1997B4008066DD /* DateInstance.h in Headers */ = {isa = PBXBuildFile; fileRef = BC1166010E1997B1008066DD /* DateInstance.h */; };
BC11667B0E199C05008066DD /* InternalFunction.h in Headers */ = {isa = PBXBuildFile; fileRef = BC11667A0E199C05008066DD /* InternalFunction.h */; settings = {ATTRIBUTES = (Private, ); }; };
BC18C3E40E16F5CD00B34460 /* AlwaysInline.h in Headers */ = {isa = PBXBuildFile; fileRef = 93AA4F770957251F0084B3A7 /* AlwaysInline.h */; settings = {ATTRIBUTES = (Private, ); }; };
BC18C3E50E16F5CD00B34460 /* APICast.h in Headers */ = {isa = PBXBuildFile; fileRef = 1482B78A0A4305AB00517CFC /* APICast.h */; settings = {ATTRIBUTES = (Private, ); }; };
BC18C3E60E16F5CD00B34460 /* ArrayConstructor.h in Headers */ = {isa = PBXBuildFile; fileRef = BC7952070E15E8A800A898AB /* ArrayConstructor.h */; };
......@@ -598,6 +599,7 @@
BC02E9B90E184580000F9297 /* JSNumberCell.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSNumberCell.cpp; sourceTree = "<group>"; };
BC1166000E1997B1008066DD /* DateInstance.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DateInstance.cpp; sourceTree = "<group>"; };
BC1166010E1997B1008066DD /* DateInstance.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DateInstance.h; sourceTree = "<group>"; };
BC11667A0E199C05008066DD /* InternalFunction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InternalFunction.h; sourceTree = "<group>"; };
BC18C3C00E16EE3300B34460 /* StringConstructor.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = StringConstructor.cpp; sourceTree = "<group>"; };
BC18C3C10E16EE3300B34460 /* StringConstructor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = StringConstructor.h; sourceTree = "<group>"; };
BC18C3C20E16EE3300B34460 /* StringObject.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = StringObject.cpp; sourceTree = "<group>"; };
......@@ -1073,6 +1075,7 @@
E178636C0D9BEEC300D74E75 /* InitializeThreading.cpp */,
E178633F0D9BEC0000D74E75 /* InitializeThreading.h */,
BC9BB95B0E19680600DF8855 /* InternalFunction.cpp */,
BC11667A0E199C05008066DD /* InternalFunction.h */,
F692A8630255597D01FF60F7 /* interpreter.cpp */,
F692A8640255597D01FF60F7 /* interpreter.h */,
14DA818F0D99FD2000B0A4FB /* JSActivation.cpp */,
......@@ -1407,6 +1410,7 @@
BC02E9130E1839DB000F9297 /* NativeErrorPrototype.h in Headers */,
BC02E98D0E183E38000F9297 /* ErrorInstance.h in Headers */,
BC1166020E1997B4008066DD /* DateInstance.h in Headers */,
BC11667B0E199C05008066DD /* InternalFunction.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
......
......@@ -21,7 +21,7 @@
#ifndef ArrayConstructor_h
#define ArrayConstructor_h
#include "JSFunction.h"
#include "InternalFunction.h"
namespace KJS {
......
......@@ -21,7 +21,7 @@
#ifndef BooleanConstructor_h
#define BooleanConstructor_h
#include "JSFunction.h"
#include "InternalFunction.h"
namespace KJS {
......
......@@ -21,7 +21,7 @@
#ifndef DateConstructor_h
#define DateConstructor_h
#include "JSFunction.h"
#include "InternalFunction.h"
namespace KJS {
......
......@@ -21,7 +21,7 @@
#ifndef ErrorConstructor_h
#define ErrorConstructor_h
#include "JSFunction.h"
#include "InternalFunction.h"
namespace KJS {
......
......@@ -23,7 +23,7 @@
#ifndef FunctionConstructor_h
#define FunctionConstructor_h
#include "JSFunction.h"
#include "InternalFunction.h"
namespace KJS {
......
......@@ -23,7 +23,7 @@
#ifndef FunctionPrototype_h
#define FunctionPrototype_h
#include "JSFunction.h"
#include "InternalFunction.h"
namespace KJS {
......
/*
* Copyright (C) 1999-2000 Harri Porten (porten@kde.org)
* Copyright (C) 2003, 2006, 2007, 2008 Apple Inc. All rights reserved.
* Copyright (C) 2007 Cameron Zwarich (cwzwarich@uwaterloo.ca)
* Copyright (C) 2007 Maks Orlovich
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public License
* along with this library; see the file COPYING.LIB. If not, write to
* the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
* Boston, MA 02110-1301, USA.
*
*/
#ifndef InternalFunction_h
#define InternalFunction_h
#include "identifier.h"
#include "JSObject.h"
namespace KJS {
class FunctionPrototype;
class InternalFunction : public JSObject {
public:
static const ClassInfo info;
virtual const ClassInfo* classInfo() const { return &info; }
const Identifier& functionName() const { return m_name; }
protected:
InternalFunction();
InternalFunction(FunctionPrototype*, const Identifier&);
private:
virtual CallType getCallData(CallData&) = 0;
virtual bool implementsHasInstance() const;
Identifier m_name;
};
} // namespace KJS
#endif // InternalFunction_h
// -*- c-basic-offset: 2 -*-
/*
* Copyright (C) 1999-2000 Harri Porten (porten@kde.org)
* Copyright (C) 2003, 2006, 2007, 2008 Apple Inc. All rights reserved.
......@@ -25,6 +24,7 @@
#ifndef JSFunction_h
#define JSFunction_h
#include "InternalFunction.h"
#include "JSVariableObject.h"
#include "SymbolTable.h"
#include "nodes.h"
......@@ -37,23 +37,6 @@ namespace KJS {
class JSActivation;
class JSGlobalObject;
class InternalFunction : public JSObject {
public:
static const ClassInfo info;
virtual const ClassInfo* classInfo() const { return &info; }
const Identifier& functionName() const { return m_name; }
protected:
InternalFunction();
InternalFunction(FunctionPrototype*, const Identifier&);
private:
virtual CallType getCallData(CallData&) = 0;
virtual bool implementsHasInstance() const;
Identifier m_name;
};
class JSFunction : public InternalFunction {
public:
JSFunction(ExecState*, const Identifier&, FunctionBodyNode*, ScopeChainNode*);
......
......@@ -21,7 +21,7 @@
#ifndef NativeErrorConstructor_h
#define NativeErrorConstructor_h
#include "JSFunction.h"
#include "InternalFunction.h"
namespace KJS {
......
......@@ -22,7 +22,7 @@
#ifndef NumberConstructor_h
#define NumberConstructor_h
#include "JSFunction.h"
#include "InternalFunction.h"
namespace KJS {
......
......@@ -21,7 +21,7 @@
#ifndef ObjectConstructor_h
#define ObjectConstructor_h
#include "JSFunction.h"
#include "InternalFunction.h"
namespace KJS {
......
......@@ -21,7 +21,7 @@
#ifndef RegExpConstructor_h
#define RegExpConstructor_h
#include "JSFunction.h"
#include "InternalFunction.h"
namespace KJS {
......
......@@ -21,7 +21,7 @@
#ifndef StringConstructor_h
#define StringConstructor_h
#include "JSFunction.h"
#include "InternalFunction.h"
namespace KJS {
......
......@@ -31,10 +31,9 @@
#include "ExecState.h"
#include "JSFunction.h"
#include "ProfileNode.h"
#include "JSGlobalObject.h"
#include "Profile.h"
#include "ProfileNode.h"
#include <stdio.h>
namespace KJS {
......
2008-06-30 Sam Weinig <sam@webkit.org>
Rubber-stamped by Darin Adler.
Split InternalFunction into its own header file.
* ForwardingHeaders/kjs/InternalFunction.h: Added.
* bridge/runtime_method.h:
2008-06-30 Adele Peterson <adele@apple.com>
Reviewed by Anders.
#include <JavaScriptCore/InternalFunction.h>
......@@ -26,8 +26,9 @@
#ifndef RUNTIME_FUNCTION_H_
#define RUNTIME_FUNCTION_H_
#include <kjs/JSFunction.h>
#include "runtime.h"
#include <kjs/InternalFunction.h>
#include <wtf/OwnPtr.h>
namespace KJS {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment