Chromium Code Reviews| Index: src/hydrogen-instructions.h |
| =================================================================== |
| --- src/hydrogen-instructions.h (revision 8716) |
| +++ src/hydrogen-instructions.h (working copy) |
| @@ -933,8 +933,12 @@ |
| class HBranch: public HUnaryControlInstruction { |
| public: |
| - HBranch(HValue* value, HBasicBlock* true_target, HBasicBlock* false_target) |
| - : HUnaryControlInstruction(value, true_target, false_target) { |
| + HBranch(HValue* value, |
| + HBasicBlock* true_target, |
| + HBasicBlock* false_target, |
| + ToBooleanStub::Types expected_input_types = ToBooleanStub::Types()) |
|
fschneider
2011/07/25 11:55:19
Maybe use a named constant ToBooleanStub::kNoTypes
Sven Panne
2011/07/25 14:06:32
Done, but because C++ is a bit broken regarding co
|
| + : HUnaryControlInstruction(value, true_target, false_target), |
| + expected_input_types_(expected_input_types) { |
| ASSERT(true_target != NULL && false_target != NULL); |
| } |
| explicit HBranch(HValue* value) |
| @@ -945,7 +949,14 @@ |
| return Representation::None(); |
| } |
| + ToBooleanStub::Types expected_input_types() const { |
| + return expected_input_types_; |
| + } |
| + |
| DECLARE_CONCRETE_INSTRUCTION(Branch) |
| + |
| + private: |
| + ToBooleanStub::Types expected_input_types_; |
| }; |