| Index: compiler/java/com/google/dart/compiler/ast/DartReturnBlock.java
|
| diff --git a/compiler/java/com/google/dart/compiler/ast/DartReturnBlock.java b/compiler/java/com/google/dart/compiler/ast/DartReturnBlock.java
|
| index a47bb20e0b5d1f3ba30e42e7438fb2bf0e86ccc4..2ab69ce540bf15a420c36b5177ef3b28ad1ad2b8 100644
|
| --- a/compiler/java/com/google/dart/compiler/ast/DartReturnBlock.java
|
| +++ b/compiler/java/com/google/dart/compiler/ast/DartReturnBlock.java
|
| @@ -9,14 +9,21 @@ import com.google.common.collect.Lists;
|
| * Represents a Dart block containing a single return statement.
|
| */
|
| public class DartReturnBlock extends DartBlock {
|
| - public DartReturnBlock(DartExpression returnVal) {
|
| - super(Lists.<DartStatement> newArrayList(new DartReturnStatement(returnVal)));
|
| + private final DartExpression value;
|
| +
|
| + public DartReturnBlock(DartExpression value) {
|
| + super(Lists.<DartStatement> newArrayList(new DartReturnStatement(value)));
|
| + this.value = value;
|
| // Set the source information for the synthesized node.
|
| - getStatements().get(0).setSourceInfo(returnVal.getSourceInfo());
|
| + getStatements().get(0).setSourceInfo(value.getSourceInfo());
|
| }
|
|
|
| @Override
|
| public <R> R accept(ASTVisitor<R> visitor) {
|
| return visitor.visitReturnBlock(this);
|
| }
|
| +
|
| + public DartExpression getValue() {
|
| + return value;
|
| + }
|
| }
|
|
|