Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(11)

Side by Side Diff: third_party/WebKit/Source/platform/wtf/HashMap.h

Issue 2804953004: Migrate WTF::HashTable::add() to ::insert() (Closed)
Patch Set: Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/wtf/HashSet.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserved.
3 * 3 *
4 * This library is free software; you can redistribute it and/or 4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public 5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either 6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version. 7 * version 2 of the License, or (at your option) any later version.
8 * 8 *
9 * This library is distributed in the hope that it will be useful, 9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 505 matching lines...) Expand 10 before | Expand all | Expand 10 after
516 template <typename T, 516 template <typename T,
517 typename U, 517 typename U,
518 typename V, 518 typename V,
519 typename W, 519 typename W,
520 typename X, 520 typename X,
521 typename Y> 521 typename Y>
522 template <typename IncomingKeyType, typename IncomingMappedType> 522 template <typename IncomingKeyType, typename IncomingMappedType>
523 typename HashMap<T, U, V, W, X, Y>::AddResult 523 typename HashMap<T, U, V, W, X, Y>::AddResult
524 HashMap<T, U, V, W, X, Y>::inlineAdd(IncomingKeyType&& key, 524 HashMap<T, U, V, W, X, Y>::inlineAdd(IncomingKeyType&& key,
525 IncomingMappedType&& mapped) { 525 IncomingMappedType&& mapped) {
526 return m_impl.template add<HashMapTranslator<ValueTraits, HashFunctions>>( 526 return m_impl.template insert<HashMapTranslator<ValueTraits, HashFunctions>>(
527 std::forward<IncomingKeyType>(key), 527 std::forward<IncomingKeyType>(key),
528 std::forward<IncomingMappedType>(mapped)); 528 std::forward<IncomingMappedType>(mapped));
529 } 529 }
530 530
531 template <typename T, 531 template <typename T,
532 typename U, 532 typename U,
533 typename V, 533 typename V,
534 typename W, 534 typename W,
535 typename X, 535 typename X,
536 typename Y> 536 typename Y>
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
737 iterator end = collection.end().values(); 737 iterator end = collection.end().values();
738 for (unsigned i = 0; it != end; ++it, ++i) 738 for (unsigned i = 0; it != end; ++it, ++i)
739 vector[i] = *it; 739 vector[i] = *it;
740 } 740 }
741 741
742 } // namespace WTF 742 } // namespace WTF
743 743
744 using WTF::HashMap; 744 using WTF::HashMap;
745 745
746 #endif // WTF_HashMap_h 746 #endif // WTF_HashMap_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/wtf/HashSet.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698