| Index: src/ast.cc
|
| diff --git a/src/ast.cc b/src/ast.cc
|
| index 2077f87d74153ba31e6fc94250a89508c3aeddda..e0bca67aab1bd32545fd2d1c498c459934fb15f5 100644
|
| --- a/src/ast.cc
|
| +++ b/src/ast.cc
|
| @@ -304,6 +304,17 @@ void UnaryOperation::RecordToBooleanTypeFeedback(TypeFeedbackOracle* oracle) {
|
| }
|
|
|
|
|
| +bool UnaryOperation::ResultOverwriteAllowed() {
|
| + switch (op_) {
|
| + case Token::BIT_NOT:
|
| + case Token::SUB:
|
| + return true;
|
| + default:
|
| + return false;
|
| + }
|
| +}
|
| +
|
| +
|
| void BinaryOperation::RecordToBooleanTypeFeedback(TypeFeedbackOracle* oracle) {
|
| // TODO(olivf) If this Operation is used in a test context, then the right
|
| // hand side has a ToBoolean stub and we want to collect the type information.
|
|
|