Ignore:
Timestamp:
Mar 2, 2006, 1:12:06 AM (19 years ago)
Author:
mjs
Message:

JavaScriptCore:

Reviewed by Darin.


  • Set up new prototype macros and avoid using #if without defined() in JSC


Added new PLATFORM macros and related, to make sure #if's all check if relevant macros
are defined, and to separate core OS-level dependencies from operating environment
dependencies so you can, e.g., build KDE on Mac or Windows.

  • kxmlcore/Platform.h: Added.


  • JavaScriptCore.xcodeproj/project.pbxproj:
  • bindings/jni/jni_utility.cpp: (KJS::Bindings::convertValueToJValue):
  • bindings/objc/WebScriptObject.mm:
  • bindings/objc/objc_instance.mm: (ObjcInstance::end):
  • bindings/softlinking.h:
  • bindings/testbindings.mm: (main):
  • kjs/JSLock.cpp:
  • kjs/collector.cpp: (KJS::Collector::markCurrentThreadConservatively): (KJS::Collector::markOtherThreadConservatively): (KJS::Collector::markStackObjectsConservatively):
  • kjs/config.h:
  • kjs/date_object.cpp: (gmtoffset): (KJS::formatTime): (KJS::DateProtoFunc::callAsFunction): (KJS::DateObjectImp::construct): (KJS::makeTime):
  • kjs/dtoa.cpp:
  • kjs/fpconst.cpp: (KJS::sizeof): (KJS::):
  • kjs/grammar.y:
  • kjs/identifier.cpp:
  • kjs/internal.cpp:
  • kjs/interpreter.cpp: (KJS::Interpreter::evaluate): (KJS::Interpreter::createLanguageInstanceForValue):
  • kjs/interpreter.h:
  • kjs/lookup.cpp:
  • kjs/lookup.h:
  • kjs/math_object.cpp:
  • kjs/object.cpp:
  • kjs/object.h:
  • kjs/operations.cpp: (KJS::isNaN): (KJS::isInf): (KJS::isPosInf): (KJS::isNegInf):
  • kjs/operations.h:
  • kjs/regexp.cpp: (KJS::RegExp::RegExp): (KJS::RegExp::~RegExp): (KJS::RegExp::match):
  • kjs/regexp.h:
  • kjs/testkjs.cpp: (StopWatch::start): (StopWatch::stop): (StopWatch::getElapsedMS):
  • kjs/ustring.cpp:
  • kjs/ustring.h:
  • kxmlcore/AlwaysInline.h:
  • kxmlcore/Assertions.cpp:
  • kxmlcore/Assertions.h:
  • kxmlcore/FastMalloc.cpp: (KXMLCore::):
  • kxmlcore/FastMalloc.h:
  • kxmlcore/FastMallocInternal.h:
  • kxmlcore/HashTable.h:
  • kxmlcore/TCPageMap.h:
  • kxmlcore/TCSpinLock.h: (TCMalloc_SpinLock::Lock): (TCMalloc_SpinLock::Unlock): (TCMalloc_SlowLock):
  • kxmlcore/TCSystemAlloc.cpp: (TCMalloc_SystemAlloc):
  • os-win32/stdint.h:

JavaScriptGlue:

Not reviewed, but I noticed these trivial extra changes were needed to avoid
breaking the build with my reviewed patch for:


http://bugzilla.opendarwin.org/show_bug.cgi?id=7387


Add config.h, includes of it, and Platform.h forwarding header.

  • JSBase.cpp:
  • JSObject.cpp:
  • JSRun.cpp:
  • JSUtils.cpp:
  • JSValueWrapper.cpp:
  • JavaScriptGlue.cpp:
  • UserObjectImp.cpp:
  • config.h: Added.
  • kxmlcore/Platform.h: Added.

WebCore:

Reviewed by Darin.


Add Platform.h

  • ForwardingHeaders/kxmlcore/Platform.h: Added.
  • bridge/mac/WebCoreFrameNamespaces.m:
  • bridge/mac/WebCoreViewFactory.m:
  • bridge/mac/WebDashboardRegion.m:
  • config.h:
  • platform/Logging.cpp:
  • platform/mac/ScrollViewMac.mm: (WebCore::ScrollView::addChild):
  • platform/mac/WebCoreCookieAdapter.m:
  • platform/mac/WebCoreGraphicsBridge.m:
  • platform/mac/WebCoreHistory.m:
  • platform/mac/WebCoreImageRendererFactory.m:
  • platform/mac/WebCoreKeyGenerator.m:
  • platform/mac/WebCoreView.m:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/kxmlcore/TCSystemAlloc.cpp

    r11962 r13089  
    3232
    3333#include "config.h"
    34 #if defined HAVE_STDINT_H
     34#if HAVE(STDINT_H)
    3535#include <stdint.h>
    36 #elif defined HAVE_INTTYPES_H
     36#elif HAVE(INTTYPES_H)
    3737#include <inttypes.h>
    3838#else
    3939#include <sys/types.h>
    4040#endif
    41 #ifndef WIN32
     41#if !PLATFORM(WIN_OS)
    4242#include <unistd.h>
    4343#include <sys/mman.h>
     
    9292#endif
    9393
    94 #ifdef HAVE_SBRK
     94#if HAVE(SBRK)
    9595
    9696static void* TrySbrk(size_t size, size_t alignment) {
     
    128128}
    129129
    130 #endif /* HAVE_SBRK */
    131 
    132 #ifdef HAVE_MMAP
     130#endif /* HAVE(SBRK) */
     131
     132#if HAVE(MMAP)
    133133
    134134static void* TryMmap(size_t size, size_t alignment) {
     
    171171}
    172172
    173 #endif /* HAVE_MMAP */
     173#endif /* HAVE(MMAP) */
    174174
    175175#ifndef KXC_CHANGES
     
    269269#endif
    270270   
    271 #ifdef HAVE_SBRK
     271#if HAVE(SBRK)
    272272    if (use_sbrk && !sbrk_failure) {
    273273      void* result = TrySbrk(size, alignment);
     
    276276#endif
    277277
    278 #ifdef HAVE_MMAP   
     278#if HAVE(MMAP)   
    279279    if (use_mmap && !mmap_failure) {
    280280      void* result = TryMmap(size, alignment);
Note: See TracChangeset for help on using the changeset viewer.