Collapse testing for a list of PLATFORM() into OS() and USE() tests
https://bugs.webkit.org/show_bug.cgi?id=108018
Patch by Laszlo Gombos <l.gombos@samsung.com> on 2013-01-28
Reviewed by Eric Seidel.
No functional change as "OS(DARWIN) && USE(CF)" equals to the
following platforms: MAC, WX, QT and CHROMIUM. CHROMIUM
is not using JavaScriptCore.
* runtime/DatePrototype.cpp:
(JSC):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@141059 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/Source/JavaScriptCore/ChangeLog b/Source/JavaScriptCore/ChangeLog
index 6973c6f..9578d4b 100644
--- a/Source/JavaScriptCore/ChangeLog
+++ b/Source/JavaScriptCore/ChangeLog
@@ -1,3 +1,17 @@
+2013-01-28 Laszlo Gombos <l.gombos@samsung.com>
+
+ Collapse testing for a list of PLATFORM() into OS() and USE() tests
+ https://bugs.webkit.org/show_bug.cgi?id=108018
+
+ Reviewed by Eric Seidel.
+
+ No functional change as "OS(DARWIN) && USE(CF)" equals to the
+ following platforms: MAC, WX, QT and CHROMIUM. CHROMIUM
+ is not using JavaScriptCore.
+
+ * runtime/DatePrototype.cpp:
+ (JSC):
+
2013-01-28 Geoffrey Garen <ggaren@apple.com>
Static size inference for JavaScript objects
diff --git a/Source/JavaScriptCore/runtime/DatePrototype.cpp b/Source/JavaScriptCore/runtime/DatePrototype.cpp
index 24d1140..2ef2ca8 100644
--- a/Source/JavaScriptCore/runtime/DatePrototype.cpp
+++ b/Source/JavaScriptCore/runtime/DatePrototype.cpp
@@ -61,7 +61,7 @@
#include <sys/timeb.h>
#endif
-#if PLATFORM(MAC) || PLATFORM(IOS) || (PLATFORM(WX) && OS(DARWIN)) || (PLATFORM(QT) && OS(DARWIN))
+#if OS(DARWIN) && USE(CF)
#include <CoreFoundation/CoreFoundation.h>
#elif USE(ICU_UNICODE)
#include <unicode/udat.h>
@@ -125,9 +125,9 @@
enum LocaleDateTimeFormat { LocaleDateAndTime, LocaleDate, LocaleTime };
-#if PLATFORM(MAC) || PLATFORM(IOS) || (PLATFORM(WX) && OS(DARWIN)) || (PLATFORM(QT) && OS(DARWIN))
+#if OS(DARWIN) && USE(CF)
-// FIXME: Since this is superior to the strftime-based version, why limit this to PLATFORM(MAC)?
+// FIXME: Since this is superior to the strftime-based version, why limit this to OS(DARWIN)?
// Instead we should consider using this whenever USE(CF) is true.
static CFDateFormatterStyle styleFromArgString(const String& string, CFDateFormatterStyle defaultStyle)
@@ -337,7 +337,7 @@
return formatLocaleDate(exec, *gregorianDateTime, format);
}
-#endif // !PLATFORM(MAC) && !PLATFORM(IOS)
+#endif // OS(DARWIN) && USE(CF)
static EncodedJSValue formateDateInstance(ExecState* exec, DateTimeFormat format, bool asUTCVariant)
{