Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/compiler/js-operator.h" | 5 #include "src/compiler/js-operator.h" |
| 6 | 6 |
| 7 #include <limits> | 7 #include <limits> |
| 8 | 8 |
| 9 #include "src/base/lazy-instance.h" | 9 #include "src/base/lazy-instance.h" |
| 10 #include "src/compiler/opcodes.h" | 10 #include "src/compiler/opcodes.h" |
| (...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 377 | 377 |
| 378 const CreateArrayParameters& CreateArrayParametersOf(const Operator* op) { | 378 const CreateArrayParameters& CreateArrayParametersOf(const Operator* op) { |
| 379 DCHECK_EQ(IrOpcode::kJSCreateArray, op->opcode()); | 379 DCHECK_EQ(IrOpcode::kJSCreateArray, op->opcode()); |
| 380 return OpParameter<CreateArrayParameters>(op); | 380 return OpParameter<CreateArrayParameters>(op); |
| 381 } | 381 } |
| 382 | 382 |
| 383 | 383 |
| 384 bool operator==(CreateClosureParameters const& lhs, | 384 bool operator==(CreateClosureParameters const& lhs, |
| 385 CreateClosureParameters const& rhs) { | 385 CreateClosureParameters const& rhs) { |
| 386 return lhs.pretenure() == rhs.pretenure() && | 386 return lhs.pretenure() == rhs.pretenure() && |
| 387 lhs.shared_info().location() == rhs.shared_info().location(); | 387 lhs.shared_info().is_identical_to(rhs.shared_info()); |
|
Michael Starzinger
2015/11/20 17:11:43
Please don't! The equality operator needs to be ba
oth
2015/11/21 14:19:47
Okay. I haved fixed the matcher here as the proble
| |
| 388 } | 388 } |
| 389 | 389 |
| 390 | 390 |
| 391 bool operator!=(CreateClosureParameters const& lhs, | 391 bool operator!=(CreateClosureParameters const& lhs, |
| 392 CreateClosureParameters const& rhs) { | 392 CreateClosureParameters const& rhs) { |
| 393 return !(lhs == rhs); | 393 return !(lhs == rhs); |
| 394 } | 394 } |
| 395 | 395 |
| 396 | 396 |
| 397 size_t hash_value(CreateClosureParameters const& p) { | 397 size_t hash_value(CreateClosureParameters const& p) { |
| (...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 775 return new (zone()) Operator1<Handle<ScopeInfo>>( // -- | 775 return new (zone()) Operator1<Handle<ScopeInfo>>( // -- |
| 776 IrOpcode::kJSCreateScriptContext, Operator::kNoProperties, // opcode | 776 IrOpcode::kJSCreateScriptContext, Operator::kNoProperties, // opcode |
| 777 "JSCreateScriptContext", // name | 777 "JSCreateScriptContext", // name |
| 778 1, 1, 1, 1, 1, 2, // counts | 778 1, 1, 1, 1, 1, 2, // counts |
| 779 scpope_info); // parameter | 779 scpope_info); // parameter |
| 780 } | 780 } |
| 781 | 781 |
| 782 } // namespace compiler | 782 } // namespace compiler |
| 783 } // namespace internal | 783 } // namespace internal |
| 784 } // namespace v8 | 784 } // namespace v8 |
| OLD | NEW |