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

Side by Side Diff: third_party/WebKit/Source/core/xml/XPathVariableReference.cpp

Issue 2709033003: Migrate WTF::HashMap::get() to ::at() (Closed)
Patch Set: rebase Created 3 years, 10 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
OLDNEW
1 /* 1 /*
2 * Copyright 2005 Frerich Raabe <raabe@kde.org> 2 * Copyright 2005 Frerich Raabe <raabe@kde.org>
3 * Copyright (C) 2006 Apple Computer, Inc. 3 * Copyright (C) 2006 Apple Computer, Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 22 matching lines...) Expand all
33 33
34 VariableReference::VariableReference(const String& name) : m_name(name) {} 34 VariableReference::VariableReference(const String& name) : m_name(name) {}
35 35
36 Value VariableReference::evaluate(EvaluationContext& context) const { 36 Value VariableReference::evaluate(EvaluationContext& context) const {
37 HashMap<String, String>& bindings = context.variableBindings; 37 HashMap<String, String>& bindings = context.variableBindings;
38 if (!bindings.contains(m_name)) { 38 if (!bindings.contains(m_name)) {
39 // FIXME: Is this the right thing to do if an unknown variable is 39 // FIXME: Is this the right thing to do if an unknown variable is
40 // referenced? 40 // referenced?
41 return ""; 41 return "";
42 } 42 }
43 return bindings.get(m_name); 43 return bindings.at(m_name);
44 } 44 }
45 45
46 } // namespace XPath 46 } // namespace XPath
47 } // namespace blink 47 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/workers/Worklet.cpp ('k') | third_party/WebKit/Source/core/xml/XSLTProcessor.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698