Commit 83a3119e authored by zandobersek@gmail.com's avatar zandobersek@gmail.com

Explicitly use the std:: nested name specifier when using std::pair, std::make_pair

https://bugs.webkit.org/show_bug.cgi?id=126439

Reviewed by Andreas Kling.

Source/JavaScriptCore: 

Instead of relying on std::pair and std::make_pair symbols being present in the current scope
through the pair and make_pair symbols, the std:: specifier should be used explicitly.

* bytecode/Opcode.cpp:
(JSC::compareOpcodePairIndices):
(JSC::OpcodeStats::~OpcodeStats):
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::BytecodeGenerator):
* parser/ASTBuilder.h:
(JSC::ASTBuilder::makeBinaryNode):
* parser/Parser.cpp:
(JSC::Parser<LexerType>::parseIfStatement):
* runtime/Structure.cpp:
(JSC::StructureTransitionTable::contains):
(JSC::StructureTransitionTable::get):
(JSC::StructureTransitionTable::add):

Source/WebCore: 

Instead of relying on std::pair and std::make_pair symbols being present in the current scope
through the pair and make_pair symbols, the std:: specifier should be used explicitly.

* Modules/webdatabase/DatabaseTracker.cpp:
(WebCore::DatabaseTracker::scheduleNotifyDatabaseChanged):
* accessibility/AXObjectCache.h:
* accessibility/AccessibilityARIAGridCell.cpp:
(WebCore::AccessibilityARIAGridCell::rowIndexRange):
(WebCore::AccessibilityARIAGridCell::columnIndexRange):
* accessibility/AccessibilityARIAGridCell.h:
* accessibility/AccessibilityObject.h:
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::mathPrescripts):
(WebCore::AccessibilityRenderObject::mathPostscripts):
* accessibility/AccessibilityTable.cpp:
(WebCore::AccessibilityTable::cellForColumnAndRow):
* accessibility/AccessibilityTableCell.cpp:
(WebCore::AccessibilityTableCell::rowIndexRange):
(WebCore::AccessibilityTableCell::columnIndexRange):
* accessibility/AccessibilityTableCell.h:
* accessibility/atk/WebKitAccessibleInterfaceTable.cpp:
(webkitAccessibleTableGetColumnAtIndex):
(webkitAccessibleTableGetRowAtIndex):
(webkitAccessibleTableGetColumnExtentAt):
(webkitAccessibleTableGetRowExtentAt):
(webkitAccessibleTableGetColumnHeader):
(webkitAccessibleTableGetRowHeader):
* accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
(-[WebAccessibilityObjectWrapper accessibilityHeaderElements]):
(-[WebAccessibilityObjectWrapper accessibilityRowRange]):
(-[WebAccessibilityObjectWrapper accessibilityColumnRange]):
* accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
(convertMathPairsToNSArray):
* accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
* bindings/js/SerializedScriptValue.cpp:
* dom/ContainerNode.cpp:
* dom/StyledElement.cpp:
(WebCore::attributeNameSort):
* html/MediaFragmentURIParser.cpp:
(WebCore::MediaFragmentURIParser::parseTimeFragment):
* html/parser/HTMLMetaCharsetParser.h:
* inspector/ContentSearchUtils.cpp:
(WebCore::ContentSearchUtils::getRegularExpressionMatchesByLines):
(WebCore::ContentSearchUtils::searchInTextByLines):
* inspector/DOMPatchSupport.cpp:
(WebCore::DOMPatchSupport::diff):
(WebCore::DOMPatchSupport::innerPatchChildren):
* inspector/DOMPatchSupport.h:
* inspector/InspectorAgent.cpp:
(WebCore::InspectorAgent::enable):
(WebCore::InspectorAgent::evaluateForTestInFrontend):
* inspector/InspectorAgent.h:
* loader/FormSubmission.cpp:
(WebCore::FormSubmission::create):
* loader/cache/CachedImage.cpp:
(WebCore::CachedImage::brokenImage):
* loader/cache/CachedImage.h:
* platform/URL.cpp:
(WebCore::findHostnamesInMailToURL):
(WebCore::encodeHostnames):
* platform/blackberry/CookieDatabaseBackingStore/CookieDatabaseBackingStore.h:
* platform/graphics/FontCache.cpp:
(WebCore::FontCache::getCachedFontData):
* platform/graphics/WidthIterator.cpp:
* platform/network/HTTPHeaderMap.cpp:
(WebCore::HTTPHeaderMap::adopt):
* platform/network/ResourceResponseBase.cpp:
(WebCore::ResourceResponseBase::parseCacheControlDirectives):
(WebCore::parseCacheHeader):
* platform/text/AtomicStringKeyedMRUCache.h:
* platform/text/LineBreakIteratorPoolICU.h:
* rendering/InlineFlowBox.h:
* rendering/RenderImage.cpp:
(WebCore::RenderImage::imageSizeForError):
(WebCore::RenderImage::paintReplaced):
* rendering/RenderTableSection.cpp:
(WebCore::RenderTableSection::cachedCollapsedBorder):
* rendering/RenderTableSection.h:
* rendering/svg/SVGTextRunRenderingContext.cpp:
(WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
* svg/SVGAnimatedAngle.cpp:
(WebCore::SVGAnimatedAngleAnimator::constructFromString):
(WebCore::SVGAnimatedAngleAnimator::addAnimatedTypes):
(WebCore::SVGAnimatedAngleAnimator::calculateAnimatedValue):
* svg/SVGAnimatedIntegerOptionalInteger.cpp:
(WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::constructFromString):
(WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::addAnimatedTypes):
(WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::calculateAnimatedValue):
* svg/SVGAnimatedNumberOptionalNumber.cpp:
(WebCore::SVGAnimatedNumberOptionalNumberAnimator::constructFromString):
(WebCore::SVGAnimatedNumberOptionalNumberAnimator::addAnimatedTypes):
(WebCore::SVGAnimatedNumberOptionalNumberAnimator::calculateAnimatedValue):
* svg/SVGAnimatedType.cpp:
(WebCore::SVGAnimatedType::createIntegerOptionalInteger):
(WebCore::SVGAnimatedType::createNumberOptionalNumber):
* svg/SVGAnimatedType.h:
(WebCore::SVGAnimatedType::integerOptionalInteger):
(WebCore::SVGAnimatedType::numberOptionalNumber):
* svg/SVGAnimatedTypeAnimator.h:
(WebCore::SVGAnimatedTypeAnimator::constructFromBaseValues):
(WebCore::SVGAnimatedTypeAnimator::resetFromBaseValues):
* svg/SVGParserUtilities.h:
* svg/animation/SMILTimeContainer.h:

Source/WebKit/mac: 

Instead of relying on std::pair and std::make_pair symbols being present in the current scope
through the pair and make_pair symbols, the std:: specifier should be used explicitly.

* Plugins/Hosted/NetscapePluginInstanceProxy.h:
* Plugins/Hosted/NetscapePluginInstanceProxy.mm:
(WebKit::NetscapePluginInstanceProxy::LocalObjectMap::idForObject):
(WebKit::NetscapePluginInstanceProxy::LocalObjectMap::retain):
(WebKit::NetscapePluginInstanceProxy::LocalObjectMap::release):
(WebKit::NetscapePluginInstanceProxy::LocalObjectMap::forget):

Source/WebKit2: 

Instead of relying on std::pair and std::make_pair symbols being present in the current scope
through the pair and make_pair symbols, the std:: specifier should be used explicitly.

* Shared/mac/ArgumentCodersMac.mm:
(IPC::encode):
* UIProcess/Notifications/WebNotificationManagerProxy.cpp:
(WebKit::WebNotificationManagerProxy::show):
(WebKit::WebNotificationManagerProxy::cancel):
(WebKit::WebNotificationManagerProxy::didDestroyNotification):
* UIProcess/Notifications/WebNotificationManagerProxy.h:
* UIProcess/WebContext.cpp:
(WebKit::WebContext::createNewWebProcess):
* UIProcess/WebContext.h:

Source/WTF: 

* wtf/VectorTraits.h: Stop bringing std::pair into the current scope.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161309 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 2af215e5
2014-01-04 Zan Dobersek <zdobersek@igalia.com>
Explicitly use the std:: nested name specifier when using std::pair, std::make_pair
https://bugs.webkit.org/show_bug.cgi?id=126439
Reviewed by Andreas Kling.
Instead of relying on std::pair and std::make_pair symbols being present in the current scope
through the pair and make_pair symbols, the std:: specifier should be used explicitly.
* bytecode/Opcode.cpp:
(JSC::compareOpcodePairIndices):
(JSC::OpcodeStats::~OpcodeStats):
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::BytecodeGenerator):
* parser/ASTBuilder.h:
(JSC::ASTBuilder::makeBinaryNode):
* parser/Parser.cpp:
(JSC::Parser<LexerType>::parseIfStatement):
* runtime/Structure.cpp:
(JSC::StructureTransitionTable::contains):
(JSC::StructureTransitionTable::get):
(JSC::StructureTransitionTable::add):
2014-01-03 David Farler <dfarler@apple.com>
[super dealloc] missing in Source/JavaScriptCore/API/tests/testapi.mm, fails to build with -Werror,-Wobjc-missing-super-calls
......
......@@ -78,9 +78,9 @@ static int compareOpcodeIndices(const void* left, const void* right)
static int compareOpcodePairIndices(const void* left, const void* right)
{
pair<int, int> leftPair = *(pair<int, int>*) left;
std::pair<int, int> leftPair = *(pair<int, int>*) left;
long long leftValue = OpcodeStats::opcodePairCounts[leftPair.first][leftPair.second];
pair<int, int> rightPair = *(pair<int, int>*) right;
std::pair<int, int> rightPair = *(pair<int, int>*) right;
long long rightValue = OpcodeStats::opcodePairCounts[rightPair.first][rightPair.second];
if (leftValue < rightValue)
......@@ -107,12 +107,12 @@ OpcodeStats::~OpcodeStats()
sortedIndices[i] = i;
qsort(sortedIndices.data(), numOpcodeIDs, sizeof(int), compareOpcodeIndices);
pair<int, int> sortedPairIndices[numOpcodeIDs * numOpcodeIDs];
pair<int, int>* currentPairIndex = sortedPairIndices;
std::pair<int, int> sortedPairIndices[numOpcodeIDs * numOpcodeIDs];
std::pair<int, int>* currentPairIndex = sortedPairIndices;
for (int i = 0; i < numOpcodeIDs; ++i)
for (int j = 0; j < numOpcodeIDs; ++j)
*(currentPairIndex++) = make_pair(i, j);
qsort(sortedPairIndices, numOpcodeIDs * numOpcodeIDs, sizeof(pair<int, int>), compareOpcodePairIndices);
*(currentPairIndex++) = std::make_pair(i, j);
qsort(sortedPairIndices, numOpcodeIDs * numOpcodeIDs, sizeof(std::pair<int, int>), compareOpcodePairIndices);
dataLogF("\nExecuted opcode statistics\n");
......@@ -129,7 +129,7 @@ OpcodeStats::~OpcodeStats()
dataLogF("2-opcode sequences by frequency: %lld\n\n", totalInstructions);
for (int i = 0; i < numOpcodeIDs * numOpcodeIDs; ++i) {
pair<int, int> indexPair = sortedPairIndices[i];
std::pair<int, int> indexPair = sortedPairIndices[i];
long long count = opcodePairCounts[indexPair.first][indexPair.second];
if (!count)
......@@ -150,7 +150,7 @@ OpcodeStats::~OpcodeStats()
dataLogF("\n%s:%s %lld - %.2f%%\n", opcodeNames[index], padOpcodeName((OpcodeID)index, 28), opcodeCount, opcodeProportion * 100.0);
for (int j = 0; j < numOpcodeIDs * numOpcodeIDs; ++j) {
pair<int, int> indexPair = sortedPairIndices[j];
std::pair<int, int> indexPair = sortedPairIndices[j];
long long pairCount = opcodePairCounts[indexPair.first][indexPair.second];
double pairProportion = ((double) pairCount) / ((double) totalInstructionPairs);
......
......@@ -381,7 +381,7 @@ BytecodeGenerator::BytecodeGenerator(VM& vm, FunctionBodyNode* functionBody, Unl
m_codeBlock->addParameter();
RegisterID& parameter = registerFor(index);
parameter.setIndex(index);
deconstructedParameters.append(make_pair(&parameter, pattern));
deconstructedParameters.append(std::make_pair(&parameter, pattern));
continue;
}
auto simpleParameter = static_cast<const BindingNode*>(pattern);
......
......@@ -720,8 +720,8 @@ private:
Scope m_scope;
Vector<BinaryOperand, 10, UnsafeVectorOverflow> m_binaryOperandStack;
Vector<AssignmentInfo, 10, UnsafeVectorOverflow> m_assignmentInfoStack;
Vector<pair<int, int>, 10, UnsafeVectorOverflow> m_binaryOperatorStack;
Vector<pair<int, JSTextPosition>, 10, UnsafeVectorOverflow> m_unaryTokenStack;
Vector<std::pair<int, int>, 10, UnsafeVectorOverflow> m_binaryOperatorStack;
Vector<std::pair<int, JSTextPosition>, 10, UnsafeVectorOverflow> m_unaryTokenStack;
int m_evalCount;
};
......@@ -898,7 +898,7 @@ ExpressionNode* ASTBuilder::makeFunctionCallNode(const JSTokenLocation& location
return node;
}
ExpressionNode* ASTBuilder::makeBinaryNode(const JSTokenLocation& location, int token, pair<ExpressionNode*, BinaryOpInfo> lhs, pair<ExpressionNode*, BinaryOpInfo> rhs)
ExpressionNode* ASTBuilder::makeBinaryNode(const JSTokenLocation& location, int token, std::pair<ExpressionNode*, BinaryOpInfo> lhs, std::pair<ExpressionNode*, BinaryOpInfo> rhs)
{
switch (token) {
case OR:
......
......@@ -1427,7 +1427,7 @@ template <class TreeBuilder> TreeStatement Parser<LexerType>::parseIfStatement(T
return context.createIfStatement(ifLocation, condition, trueBlock, 0, start, end);
Vector<TreeExpression> exprStack;
Vector<pair<int, int>> posStack;
Vector<std::pair<int, int>> posStack;
Vector<JSTokenLocation> tokenLocationStack;
Vector<TreeStatement> statementStack;
bool trailingElse = false;
......@@ -1456,7 +1456,7 @@ template <class TreeBuilder> TreeStatement Parser<LexerType>::parseIfStatement(T
failIfFalse(innerTrueBlock, "Expected a statement as the body of an if block");
tokenLocationStack.append(tempLocation);
exprStack.append(innerCondition);
posStack.append(make_pair(innerStart, innerEnd));
posStack.append(std::make_pair(innerStart, innerEnd));
statementStack.append(innerTrueBlock);
} while (match(ELSE));
......@@ -1465,7 +1465,7 @@ template <class TreeBuilder> TreeStatement Parser<LexerType>::parseIfStatement(T
exprStack.removeLast();
TreeStatement trueBlock = statementStack.last();
statementStack.removeLast();
pair<int, int> pos = posStack.last();
std::pair<int, int> pos = posStack.last();
posStack.removeLast();
JSTokenLocation elseLocation = tokenLocationStack.last();
tokenLocationStack.removeLast();
......@@ -1479,7 +1479,7 @@ template <class TreeBuilder> TreeStatement Parser<LexerType>::parseIfStatement(T
statementStack.removeLast();
TreeStatement trueBlock = statementStack.last();
statementStack.removeLast();
pair<int, int> pos = posStack.last();
std::pair<int, int> pos = posStack.last();
posStack.removeLast();
JSTokenLocation elseLocation = tokenLocationStack.last();
tokenLocationStack.removeLast();
......
......@@ -71,7 +71,7 @@ bool StructureTransitionTable::contains(StringImpl* rep, unsigned attributes) co
Structure* transition = singleTransition();
return transition && transition->m_nameInPrevious == rep && transition->m_attributesInPrevious == attributes;
}
return map()->get(make_pair(rep, attributes));
return map()->get(std::make_pair(rep, attributes));
}
inline Structure* StructureTransitionTable::get(StringImpl* rep, unsigned attributes) const
......@@ -80,7 +80,7 @@ inline Structure* StructureTransitionTable::get(StringImpl* rep, unsigned attrib
Structure* transition = singleTransition();
return (transition && transition->m_nameInPrevious == rep && transition->m_attributesInPrevious == attributes) ? transition : 0;
}
return map()->get(make_pair(rep, attributes));
return map()->get(std::make_pair(rep, attributes));
}
inline void StructureTransitionTable::add(VM& vm, Structure* structure)
......@@ -105,7 +105,7 @@ inline void StructureTransitionTable::add(VM& vm, Structure* structure)
// Newer versions of the STL have an std::make_pair function that takes rvalue references.
// When either of the parameters are bitfields, the C++ compiler will try to bind them as lvalues, which is invalid. To work around this, use unary "+" to make the parameter an rvalue.
// See https://bugs.webkit.org/show_bug.cgi?id=59261 for more details
map()->set(make_pair(structure->m_nameInPrevious.get(), +structure->m_attributesInPrevious), structure);
map()->set(std::make_pair(structure->m_nameInPrevious.get(), +structure->m_attributesInPrevious), structure);
}
void Structure::dumpStatistics()
......
2014-01-04 Zan Dobersek <zdobersek@igalia.com>
Explicitly use the std:: nested name specifier when using std::pair, std::make_pair
https://bugs.webkit.org/show_bug.cgi?id=126439
Reviewed by Andreas Kling.
* wtf/VectorTraits.h: Stop bringing std::pair into the current scope.
2014-01-02 Gavin Barraclough <barraclough@apple.com>
Refactor NSActivity handling code from ChildProcess to UserActivity
......
......@@ -27,8 +27,6 @@
#include <utility>
#include <memory>
using std::pair;
namespace WTF {
class AtomicString;
......
2014-01-04 Zan Dobersek <zdobersek@igalia.com>
Explicitly use the std:: nested name specifier when using std::pair, std::make_pair
https://bugs.webkit.org/show_bug.cgi?id=126439
Reviewed by Andreas Kling.
Instead of relying on std::pair and std::make_pair symbols being present in the current scope
through the pair and make_pair symbols, the std:: specifier should be used explicitly.
* Modules/webdatabase/DatabaseTracker.cpp:
(WebCore::DatabaseTracker::scheduleNotifyDatabaseChanged):
* accessibility/AXObjectCache.h:
* accessibility/AccessibilityARIAGridCell.cpp:
(WebCore::AccessibilityARIAGridCell::rowIndexRange):
(WebCore::AccessibilityARIAGridCell::columnIndexRange):
* accessibility/AccessibilityARIAGridCell.h:
* accessibility/AccessibilityObject.h:
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::mathPrescripts):
(WebCore::AccessibilityRenderObject::mathPostscripts):
* accessibility/AccessibilityTable.cpp:
(WebCore::AccessibilityTable::cellForColumnAndRow):
* accessibility/AccessibilityTableCell.cpp:
(WebCore::AccessibilityTableCell::rowIndexRange):
(WebCore::AccessibilityTableCell::columnIndexRange):
* accessibility/AccessibilityTableCell.h:
* accessibility/atk/WebKitAccessibleInterfaceTable.cpp:
(webkitAccessibleTableGetColumnAtIndex):
(webkitAccessibleTableGetRowAtIndex):
(webkitAccessibleTableGetColumnExtentAt):
(webkitAccessibleTableGetRowExtentAt):
(webkitAccessibleTableGetColumnHeader):
(webkitAccessibleTableGetRowHeader):
* accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
(-[WebAccessibilityObjectWrapper accessibilityHeaderElements]):
(-[WebAccessibilityObjectWrapper accessibilityRowRange]):
(-[WebAccessibilityObjectWrapper accessibilityColumnRange]):
* accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
(convertMathPairsToNSArray):
* accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
* bindings/js/SerializedScriptValue.cpp:
* dom/ContainerNode.cpp:
* dom/StyledElement.cpp:
(WebCore::attributeNameSort):
* html/MediaFragmentURIParser.cpp:
(WebCore::MediaFragmentURIParser::parseTimeFragment):
* html/parser/HTMLMetaCharsetParser.h:
* inspector/ContentSearchUtils.cpp:
(WebCore::ContentSearchUtils::getRegularExpressionMatchesByLines):
(WebCore::ContentSearchUtils::searchInTextByLines):
* inspector/DOMPatchSupport.cpp:
(WebCore::DOMPatchSupport::diff):
(WebCore::DOMPatchSupport::innerPatchChildren):
* inspector/DOMPatchSupport.h:
* inspector/InspectorAgent.cpp:
(WebCore::InspectorAgent::enable):
(WebCore::InspectorAgent::evaluateForTestInFrontend):
* inspector/InspectorAgent.h:
* loader/FormSubmission.cpp:
(WebCore::FormSubmission::create):
* loader/cache/CachedImage.cpp:
(WebCore::CachedImage::brokenImage):
* loader/cache/CachedImage.h:
* platform/URL.cpp:
(WebCore::findHostnamesInMailToURL):
(WebCore::encodeHostnames):
* platform/blackberry/CookieDatabaseBackingStore/CookieDatabaseBackingStore.h:
* platform/graphics/FontCache.cpp:
(WebCore::FontCache::getCachedFontData):
* platform/graphics/WidthIterator.cpp:
* platform/network/HTTPHeaderMap.cpp:
(WebCore::HTTPHeaderMap::adopt):
* platform/network/ResourceResponseBase.cpp:
(WebCore::ResourceResponseBase::parseCacheControlDirectives):
(WebCore::parseCacheHeader):
* platform/text/AtomicStringKeyedMRUCache.h:
* platform/text/LineBreakIteratorPoolICU.h:
* rendering/InlineFlowBox.h:
* rendering/RenderImage.cpp:
(WebCore::RenderImage::imageSizeForError):
(WebCore::RenderImage::paintReplaced):
* rendering/RenderTableSection.cpp:
(WebCore::RenderTableSection::cachedCollapsedBorder):
* rendering/RenderTableSection.h:
* rendering/svg/SVGTextRunRenderingContext.cpp:
(WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
* svg/SVGAnimatedAngle.cpp:
(WebCore::SVGAnimatedAngleAnimator::constructFromString):
(WebCore::SVGAnimatedAngleAnimator::addAnimatedTypes):
(WebCore::SVGAnimatedAngleAnimator::calculateAnimatedValue):
* svg/SVGAnimatedIntegerOptionalInteger.cpp:
(WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::constructFromString):
(WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::addAnimatedTypes):
(WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::calculateAnimatedValue):
* svg/SVGAnimatedNumberOptionalNumber.cpp:
(WebCore::SVGAnimatedNumberOptionalNumberAnimator::constructFromString):
(WebCore::SVGAnimatedNumberOptionalNumberAnimator::addAnimatedTypes):
(WebCore::SVGAnimatedNumberOptionalNumberAnimator::calculateAnimatedValue):
* svg/SVGAnimatedType.cpp:
(WebCore::SVGAnimatedType::createIntegerOptionalInteger):
(WebCore::SVGAnimatedType::createNumberOptionalNumber):
* svg/SVGAnimatedType.h:
(WebCore::SVGAnimatedType::integerOptionalInteger):
(WebCore::SVGAnimatedType::numberOptionalNumber):
* svg/SVGAnimatedTypeAnimator.h:
(WebCore::SVGAnimatedTypeAnimator::constructFromBaseValues):
(WebCore::SVGAnimatedTypeAnimator::resetFromBaseValues):
* svg/SVGParserUtilities.h:
* svg/animation/SMILTimeContainer.h:
2014-01-03 Simon Fraser <simon.fraser@apple.com>
Attempt to fix EFL build.
......@@ -1124,7 +1124,7 @@ static Mutex& notificationMutex()
return mutex;
}
typedef Vector<pair<RefPtr<SecurityOrigin>, String>> NotificationQueue;
typedef Vector<std::pair<RefPtr<SecurityOrigin>, String>> NotificationQueue;
static NotificationQueue& notificationQueue()
{
......@@ -1136,7 +1136,7 @@ void DatabaseTracker::scheduleNotifyDatabaseChanged(SecurityOrigin* origin, cons
{
MutexLocker locker(notificationMutex());
notificationQueue().append(pair<RefPtr<SecurityOrigin>, String>(origin->isolatedCopy(), name.isolatedCopy()));
notificationQueue().append(std::pair<RefPtr<SecurityOrigin>, String>(origin->isolatedCopy(), name.isolatedCopy()));
scheduleForNotification();
}
......
......@@ -235,7 +235,7 @@ private:
HashSet<AXID> m_idsInUse;
Timer<AXObjectCache> m_notificationPostTimer;
Vector<pair<RefPtr<AccessibilityObject>, AXNotification>> m_notificationsToPost;
Vector<std::pair<RefPtr<AccessibilityObject>, AXNotification>> m_notificationsToPost;
void notificationPostTimerFired(Timer<AXObjectCache>*);
static AccessibilityObject* focusedImageMapUIElement(HTMLAreaElement*);
......
......@@ -68,7 +68,7 @@ AccessibilityObject* AccessibilityARIAGridCell::parentTable() const
return parent;
}
void AccessibilityARIAGridCell::rowIndexRange(pair<unsigned, unsigned>& rowRange)
void AccessibilityARIAGridCell::rowIndexRange(std::pair<unsigned, unsigned>& rowRange)
{
AccessibilityObject* parent = parentObjectUnignored();
if (!parent)
......@@ -98,7 +98,7 @@ void AccessibilityARIAGridCell::rowIndexRange(pair<unsigned, unsigned>& rowRange
rowRange.second = 1;
}
void AccessibilityARIAGridCell::columnIndexRange(pair<unsigned, unsigned>& columnRange)
void AccessibilityARIAGridCell::columnIndexRange(std::pair<unsigned, unsigned>& columnRange)
{
AccessibilityObject* parent = parentObjectUnignored();
if (!parent)
......
......@@ -42,9 +42,9 @@ public:
virtual ~AccessibilityARIAGridCell();
// fills in the start location and row span of cell
virtual void rowIndexRange(pair<unsigned, unsigned>& rowRange) OVERRIDE;
virtual void rowIndexRange(std::pair<unsigned, unsigned>& rowRange) OVERRIDE;
// fills in the start location and column span of cell
virtual void columnIndexRange(pair<unsigned, unsigned>& columnRange) OVERRIDE;
virtual void columnIndexRange(std::pair<unsigned, unsigned>& columnRange) OVERRIDE;
protected:
virtual AccessibilityObject* parentTable() const OVERRIDE;
......
......@@ -858,7 +858,7 @@ public:
virtual int mathLineThickness() const { return 0; }
// Multiscripts components.
typedef Vector<pair<AccessibilityObject*, AccessibilityObject*>> AccessibilityMathMultiscriptPairs;
typedef Vector<std::pair<AccessibilityObject*, AccessibilityObject*>> AccessibilityMathMultiscriptPairs;
virtual void mathPrescripts(AccessibilityMathMultiscriptPairs&) { }
virtual void mathPostscripts(AccessibilityMathMultiscriptPairs&) { }
......
......@@ -3716,7 +3716,7 @@ void AccessibilityRenderObject::mathPrescripts(AccessibilityMathMultiscriptPairs
return;
bool foundPrescript = false;
pair<AccessibilityObject*, AccessibilityObject*> prescriptPair;
std::pair<AccessibilityObject*, AccessibilityObject*> prescriptPair;
for (Node* child = node()->firstChild(); child; child = child->nextSibling()) {
if (foundPrescript) {
AccessibilityObject* axChild = axObjectCache()->getOrCreate(child);
......@@ -3746,7 +3746,7 @@ void AccessibilityRenderObject::mathPostscripts(AccessibilityMathMultiscriptPair
// In Multiscripts, the post-script elements start after the first element (which is the base)
// and continue until a <mprescripts> tag is found
pair<AccessibilityObject*, AccessibilityObject*> postscriptPair;
std::pair<AccessibilityObject*, AccessibilityObject*> postscriptPair;
bool foundBaseElement = false;
for (Node* child = node()->firstChild(); child; child = child->nextSibling()) {
if (child->hasTagName(MathMLNames::mprescriptsTag))
......
......@@ -519,8 +519,8 @@ AccessibilityTableCell* AccessibilityTable::cellForColumnAndRow(unsigned column,
if (!child->isTableCell())
continue;
pair<unsigned, unsigned> columnRange;
pair<unsigned, unsigned> rowRange;
std::pair<unsigned, unsigned> columnRange;
std::pair<unsigned, unsigned> rowRange;
AccessibilityTableCell* tableCellChild = toAccessibilityTableCell(child);
tableCellChild->columnIndexRange(columnRange);
tableCellChild->rowIndexRange(rowRange);
......
......@@ -104,7 +104,7 @@ AccessibilityRole AccessibilityTableCell::determineAccessibilityRole()
return CellRole;
}
void AccessibilityTableCell::rowIndexRange(pair<unsigned, unsigned>& rowRange)
void AccessibilityTableCell::rowIndexRange(std::pair<unsigned, unsigned>& rowRange)
{
if (!m_renderer || !m_renderer->isTableCell())
return;
......@@ -131,7 +131,7 @@ void AccessibilityTableCell::rowIndexRange(pair<unsigned, unsigned>& rowRange)
rowRange.first += rowOffset;
}
void AccessibilityTableCell::columnIndexRange(pair<unsigned, unsigned>& columnRange)
void AccessibilityTableCell::columnIndexRange(std::pair<unsigned, unsigned>& columnRange)
{
if (!m_renderer || !m_renderer->isTableCell())
return;
......
......@@ -44,9 +44,9 @@ public:
virtual bool isTableCell() const OVERRIDE;
// fills in the start location and row span of cell
virtual void rowIndexRange(pair<unsigned, unsigned>& rowRange);
virtual void rowIndexRange(std::pair<unsigned, unsigned>& rowRange);
// fills in the start location and column span of cell
virtual void columnIndexRange(pair<unsigned, unsigned>& columnRange);
virtual void columnIndexRange(std::pair<unsigned, unsigned>& columnRange);
protected:
virtual AccessibilityObject* parentTable() const;
......
......@@ -125,7 +125,7 @@ static gint webkitAccessibleTableGetColumnAtIndex(AtkTable* table, gint index)
AccessibilityTableCell* axCell = cellAtIndex(table, index);
if (axCell) {
pair<unsigned, unsigned> columnRange;
std::pair<unsigned, unsigned> columnRange;
axCell->columnIndexRange(columnRange);
return columnRange.first;
}
......@@ -139,7 +139,7 @@ static gint webkitAccessibleTableGetRowAtIndex(AtkTable* table, gint index)
AccessibilityTableCell* axCell = cellAtIndex(table, index);
if (axCell) {
pair<unsigned, unsigned> rowRange;
std::pair<unsigned, unsigned> rowRange;
axCell->rowIndexRange(rowRange);
return rowRange.first;
}
......@@ -175,7 +175,7 @@ static gint webkitAccessibleTableGetColumnExtentAt(AtkTable* table, gint row, gi
AccessibilityTableCell* axCell = cell(table, row, column);
if (axCell) {
pair<unsigned, unsigned> columnRange;
std::pair<unsigned, unsigned> columnRange;
axCell->columnIndexRange(columnRange);
return columnRange.second;
}
......@@ -189,7 +189,7 @@ static gint webkitAccessibleTableGetRowExtentAt(AtkTable* table, gint row, gint
AccessibilityTableCell* axCell = cell(table, row, column);
if (axCell) {
pair<unsigned, unsigned> rowRange;
std::pair<unsigned, unsigned> rowRange;
axCell->rowIndexRange(rowRange);
return rowRange.second;
}
......@@ -207,7 +207,7 @@ static AtkObject* webkitAccessibleTableGetColumnHeader(AtkTable* table, gint col
toAccessibilityTable(accTable)->columnHeaders(allColumnHeaders);
unsigned columnCount = allColumnHeaders.size();
for (unsigned k = 0; k < columnCount; ++k) {
pair<unsigned, unsigned> columnRange;
std::pair<unsigned, unsigned> columnRange;
AccessibilityTableCell* cell = toAccessibilityTableCell(allColumnHeaders.at(k).get());
cell->columnIndexRange(columnRange);
if (columnRange.first <= static_cast<unsigned>(column) && static_cast<unsigned>(column) < columnRange.first + columnRange.second)
......@@ -228,7 +228,7 @@ static AtkObject* webkitAccessibleTableGetRowHeader(AtkTable* table, gint row)
toAccessibilityTable(accTable)->rowHeaders(allRowHeaders);
unsigned rowCount = allRowHeaders.size();
for (unsigned k = 0; k < rowCount; ++k) {
pair<unsigned, unsigned> rowRange;
std::pair<unsigned, unsigned> rowRange;
AccessibilityTableCell* cell = toAccessibilityTableCell(allRowHeaders.at(k).get());
cell->rowIndexRange(rowRange);
if (rowRange.first <= static_cast<unsigned>(row) && static_cast<unsigned>(row) < rowRange.first + rowRange.second)
......
......@@ -813,8 +813,8 @@ static void appendStringToResult(NSMutableString *result, NSString *string)
return nil;
// Get the row and column range, so we can use them to find the headers.
pair<unsigned, unsigned> rowRange;
pair<unsigned, unsigned> columnRange;
std::pair<unsigned, unsigned> rowRange;
std::pair<unsigned, unsigned> columnRange;
tableCell->rowIndexRange(rowRange);
tableCell->columnIndexRange(columnRange);
......@@ -877,7 +877,7 @@ static void appendStringToResult(NSMutableString *result, NSString *string)
if (!tableCell)
return NSMakeRange(NSNotFound, 0);
pair<unsigned, unsigned> rowRange;
std::pair<unsigned, unsigned> rowRange;
tableCell->rowIndexRange(rowRange);
return NSMakeRange(rowRange.first, rowRange.second);
}
......@@ -891,7 +891,7 @@ static void appendStringToResult(NSMutableString *result, NSString *string)
if (!tableCell)
return NSMakeRange(NSNotFound, 0);
pair<unsigned, unsigned> columnRange;
std::pair<unsigned, unsigned> columnRange;
tableCell->columnIndexRange(columnRange);
return NSMakeRange(columnRange.first, columnRange.second);
}
......
......@@ -82,7 +82,7 @@ static NSArray *convertMathPairsToNSArray(const AccessibilityObject::Accessibili
NSMutableArray *array = [NSMutableArray arrayWithCapacity:length];
for (unsigned i = 0; i < length; ++i) {
NSMutableDictionary *pairDictionary = [NSMutableDictionary dictionary];
pair<AccessibilityObject*, AccessibilityObject*> pair = pairs[i];
std::pair<AccessibilityObject*, AccessibilityObject*> pair = pairs[i];
if (pair.first && pair.first->wrapper() && !pair.first->accessibilityIsIgnored())
[pairDictionary setObject:pair.first->wrapper() forKey:subscriptKey];
if (pair.second && pair.second->wrapper() && !pair.second->accessibilityIsIgnored())
......
......@@ -2480,12 +2480,12 @@ static NSString* roleValueToNSString(AccessibilityRole value)
if (m_object->isTableCell()) {
if ([attributeName isEqualToString:NSAccessibilityRowIndexRangeAttribute]) {
pair<unsigned, unsigned> rowRange;
std::pair<unsigned, unsigned> rowRange;
toAccessibilityTableCell(m_object)->rowIndexRange(rowRange);
return [NSValue valueWithRange:NSMakeRange(rowRange.first, rowRange.second)];
}
if ([attributeName isEqualToString:NSAccessibilityColumnIndexRangeAttribute]) {
pair<unsigned, unsigned> columnRange;
std::pair<unsigned, unsigned> columnRange;
toAccessibilityTableCell(m_object)->columnIndexRange(columnRange);
return [NSValue valueWithRange:NSMakeRange(columnRange.first, columnRange.second)];
}
......
......@@ -354,7 +354,7 @@ static const unsigned NonIndexPropertiesTag = 0xFFFFFFFD;
* <factorSize:uint32_t> <factor:byte{factorSize}> <crtExponentSize:uint32_t> <crtExponent:byte{crtExponentSize}> <crtCoefficientSize:uint32_t> <crtCoefficient:byte{crtCoefficientSize}>
*/
typedef pair<JSC::JSValue, SerializationReturnCode> DeserializationResult;
typedef std::pair<JSC::JSValue, SerializationReturnCode> DeserializationResult;
class CloneBase {
protected:
......
......@@ -63,8 +63,8 @@ namespace WebCore {
static void dispatchChildInsertionEvents(Node&);
static void dispatchChildRemovalEvents(Node&);
typedef pair<RefPtr<Node>, unsigned> CallbackParameters;
typedef pair<NodeCallback, CallbackParameters> CallbackInfo;
typedef std::pair<RefPtr<Node>, unsigned> CallbackParameters;
typedef std::pair<NodeCallback, CallbackParameters> CallbackInfo;
typedef Vector<CallbackInfo> NodeCallbackQueue;
static NodeCallbackQueue* s_postAttachCallbackQueue;
......
......@@ -48,7 +48,7 @@ struct PresentationAttributeCacheKey {
PresentationAttributeCacheKey() : tagName(0) { }
AtomicStringImpl* tagName;
// Only the values need refcounting.
Vector<pair<AtomicStringImpl*, AtomicString>, 3> attributesAndValues;
Vector<std::pair<AtomicStringImpl*, AtomicString>, 3> attributesAndValues;
};
struct PresentationAttributeCacheEntry {
......@@ -271,7 +271,7 @@ void StyledElement::addSubresourceAttributeURLs(ListHashSet<URL>& urls) const
inlineStyle->addSubresourceStyleURLs(urls, &document().elementSheet().contents());
}
static inline bool attributeNameSort(const pair<AtomicStringImpl*, AtomicString>& p1, const pair<AtomicStringImpl*, AtomicString>& p2)
static inline bool attributeNameSort(const std::pair<AtomicStringImpl*, AtomicString>& p1, const std::pair<AtomicStringImpl*, AtomicString>& p2)
{
// Sort based on the attribute name pointers. It doesn't matter what the order is as long as it is always the same.
return p1.first < p2.first;
......
......@@ -167,7 +167,7 @@ void MediaFragmentURIParser::parseTimeFragment()
m_timeFormat = Invalid;
for (unsigned i = 0; i < m_fragments.size(); ++i) {
pair<String, String>& fragment = m_fragments[i];
std::pair<String, String>& fragment = m_fragments[i];
ASSERT(fragment.first.is8Bit());
ASSERT(fragment.second.is8Bit());
......
......@@ -48,7 +48,7 @@ public:
const TextEncoding& encoding() { return m_encoding; }
typedef Vector<pair<String, String>> AttributeList;
typedef Vector<std::pair<String, String>> AttributeList;
// The returned encoding might not be valid.
static TextEncoding encodingFromMetaAttributes(const AttributeList&
);
......
......@@ -79,9 +79,9 @@ TextPosition textPositionFromOffset(size_t offset, const Vector<size_t>& lineEnd
return TextPosition(OrdinalNumber::fromZeroBasedInt(lineIndex), OrdinalNumber::fromZeroBasedInt(column));
}
static Vector<pair<int, String>> getRegularExpressionMatchesByLines(const RegularExpression& regex, const String& text)
static Vector<std::pair<int, String>> getRegularExpressionMatchesByLines(const RegularExpression& regex, const String& text)
{
Vector<pair<int, String>> result;
Vector<std::pair<int, String>> result;
if (text.isEmpty())
return result;
......@@ -96,7 +96,7 @@ static Vector<pair<int, String>> getRegularExpressionMatchesByLines(const Regula
int matchLength;
if (regex.match(line, 0, &matchLength) != -1)
result.append(pair<int, String>(lineNumber, line));
result.append(std::pair<int, String>(lineNumber, line));
start = lineEnd + 1;
}
......@@ -159,9 +159,9 @@ PassRefPtr<Inspector::TypeBuilder::Array<Inspector::TypeBuilder::GenericTypes::S
RefPtr<Inspector::TypeBuilder::Array<Inspector::TypeBuilder::GenericTypes::SearchMatch>> result = Inspector::TypeBuilder::Array<Inspector::TypeBuilder::GenericTypes::SearchMatch>::create();
RegularExpression regex = ContentSearchUtils::createSearchRegex(query, caseSensitive, isRegex);
Vector<pair<int, String>> matches = getRegularExpressionMatchesByLines(regex, text);
Vector<std::pair<int, String>> matches = getRegularExpressionMatchesByLines(regex, text);
for (Vector<pair<int, String>>::const_iterator it = matches.begin(); it != matches.end(); ++it)
for (Vector<std::pair<int, String>>::const_iterator it = matches.begin(); it != matches.end(); ++it)
result->addItem(buildObjectForSearchMatch(it->first, it->second));
return result;
......
......@@ -211,7 +211,7 @@ bool DOMPatchSupport::innerPatchNode(Digest* oldDigest, Digest* newDigest, Excep
return result;
}
pair<DOMPatchSupport::ResultMap, DOMPatchSupport::ResultMap>
std::pair<DOMPatchSupport::ResultMap, DOMPatchSupport::ResultMap>
DOMPatchSupport::diff(const Vector<OwnPtr<Digest>>& oldList, const Vector<OwnPtr<Digest>>& newList)
{
ResultMap newMap(newList.size());
......@@ -296,12 +296,12 @@ DOMPatchSupport::diff(const Vector<OwnPtr<Digest>>& oldList, const Vector<OwnPtr
dumpMap(newMap, "NEW");
#endif
return make_pair(oldMap, newMap);