summaryrefslogtreecommitdiffstats
path: root/JavaScriptCore/wtf/unicode
diff options
context:
space:
mode:
authorThe Android Open Source Project <initial-contribution@android.com>2009-03-05 14:34:32 -0800
committerThe Android Open Source Project <initial-contribution@android.com>2009-03-05 14:34:32 -0800
commit635860845790a19bf50bbc51ba8fb66a96dde068 (patch)
treeef6ad9ff73a5b57f65249d4232a202fa77e6a140 /JavaScriptCore/wtf/unicode
parent8e35f3cfc7fba1d1c829dc557ebad6409cbe16a2 (diff)
downloadexternal_webkit-635860845790a19bf50bbc51ba8fb66a96dde068.zip
external_webkit-635860845790a19bf50bbc51ba8fb66a96dde068.tar.gz
external_webkit-635860845790a19bf50bbc51ba8fb66a96dde068.tar.bz2
auto import from //depot/cupcake/@136594
Diffstat (limited to 'JavaScriptCore/wtf/unicode')
-rw-r--r--JavaScriptCore/wtf/unicode/Unicode.h13
-rw-r--r--JavaScriptCore/wtf/unicode/icu/CollatorICU.cpp2
-rw-r--r--JavaScriptCore/wtf/unicode/icu/UnicodeIcu.h8
-rw-r--r--JavaScriptCore/wtf/unicode/qt4/UnicodeQt4.h9
4 files changed, 17 insertions, 15 deletions
diff --git a/JavaScriptCore/wtf/unicode/Unicode.h b/JavaScriptCore/wtf/unicode/Unicode.h
index 9cd3555..e6e8f23 100644
--- a/JavaScriptCore/wtf/unicode/Unicode.h
+++ b/JavaScriptCore/wtf/unicode/Unicode.h
@@ -1,6 +1,6 @@
/*
- * This file is part of the KDE libraries
* Copyright (C) 2006 George Staikos <staikos@kde.org>
+ * Copyright (C) 2006, 2008, 2009 Apple Inc. All rights reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
@@ -19,10 +19,10 @@
*
*/
-#ifndef KJS_UNICODE_H
-#define KJS_UNICODE_H
+#ifndef WTF_UNICODE_H
+#define WTF_UNICODE_H
-#include <wtf/Platform.h>
+#include <wtf/Assertions.h>
#if USE(QT4_UNICODE)
#include "qt4/UnicodeQt4.h"
@@ -32,5 +32,6 @@
#error "Unknown Unicode implementation"
#endif
-#endif
-// vim: ts=2 sw=2 et
+COMPILE_ASSERT(sizeof(UChar) == 2, UCharIsTwoBytes);
+
+#endif // WTF_UNICODE_H
diff --git a/JavaScriptCore/wtf/unicode/icu/CollatorICU.cpp b/JavaScriptCore/wtf/unicode/icu/CollatorICU.cpp
index a8bcc81..79dec79 100644
--- a/JavaScriptCore/wtf/unicode/icu/CollatorICU.cpp
+++ b/JavaScriptCore/wtf/unicode/icu/CollatorICU.cpp
@@ -45,7 +45,7 @@ namespace WTF {
static UCollator* cachedCollator;
static Mutex& cachedCollatorMutex()
{
- AtomicallyInitializedStatic(Mutex, mutex);
+ AtomicallyInitializedStatic(Mutex&, mutex = *new Mutex);
return mutex;
}
diff --git a/JavaScriptCore/wtf/unicode/icu/UnicodeIcu.h b/JavaScriptCore/wtf/unicode/icu/UnicodeIcu.h
index 7cdc55c..608aea6 100644
--- a/JavaScriptCore/wtf/unicode/icu/UnicodeIcu.h
+++ b/JavaScriptCore/wtf/unicode/icu/UnicodeIcu.h
@@ -1,7 +1,7 @@
/*
* Copyright (C) 2006 George Staikos <staikos@kde.org>
* Copyright (C) 2006 Alexey Proskuryakov <ap@nypop.com>
- * Copyright (C) 2007 Apple Inc. All rights reserved.
+ * Copyright (C) 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
@@ -20,8 +20,8 @@
*
*/
-#ifndef KJS_UNICODE_ICU_H
-#define KJS_UNICODE_ICU_H
+#ifndef WTF_UNICODE_ICU_H
+#define WTF_UNICODE_ICU_H
#include <stdlib.h>
#include <unicode/uchar.h>
@@ -216,4 +216,4 @@ inline int umemcasecmp(const UChar* a, const UChar* b, int len)
} }
-#endif
+#endif // WTF_UNICODE_ICU_H
diff --git a/JavaScriptCore/wtf/unicode/qt4/UnicodeQt4.h b/JavaScriptCore/wtf/unicode/qt4/UnicodeQt4.h
index d285a8f..d7d78ce 100644
--- a/JavaScriptCore/wtf/unicode/qt4/UnicodeQt4.h
+++ b/JavaScriptCore/wtf/unicode/qt4/UnicodeQt4.h
@@ -1,6 +1,7 @@
/*
* Copyright (C) 2006 George Staikos <staikos@kde.org>
* Copyright (C) 2006 Alexey Proskuryakov <ap@nypop.com>
+ * Copyright (C) 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
@@ -19,8 +20,8 @@
*
*/
-#ifndef KJS_UNICODE_QT4_H
-#define KJS_UNICODE_QT4_H
+#ifndef WTF_UNICODE_QT4_H
+#define WTF_UNICODE_QT4_H
#include <QChar>
#include <QString>
@@ -170,7 +171,7 @@ enum CharCategory {
Symbol_Math = U_MASK(QChar::Symbol_Math),
Symbol_Currency = U_MASK(QChar::Symbol_Currency),
Symbol_Modifier = U_MASK(QChar::Symbol_Modifier),
- Symbol_Other = U_MASK(QChar::Symbol_Other),
+ Symbol_Other = U_MASK(QChar::Symbol_Other)
};
@@ -522,4 +523,4 @@ inline CharCategory category(UChar32 c)
} }
-#endif
+#endif // WTF_UNICODE_QT4_H