Mercurial > hg > graal-jvmci-8
comparison graal/com.oracle.truffle.api.test/src/com/oracle/truffle/api/test/ReplaceTest.java @ 11903:df1d665ca846
Truffle; remove uses of Node() constructor in test code
author | Michael Van De Vanter <michael.van.de.vanter@oracle.com> |
---|---|
date | Sun, 06 Oct 2013 19:53:00 -0700 |
parents | 7f6580db1e88 |
children | a08b8694f556 |
comparison
equal
deleted
inserted
replaced
11901:61767ccd4600 | 11903:df1d665ca846 |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. | 2 * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. | 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * | 4 * |
5 * This code is free software; you can redistribute it and/or modify it | 5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as | 6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
82 class TestRootNode extends RootNode { | 82 class TestRootNode extends RootNode { |
83 | 83 |
84 @Children private final ValueNode[] children; | 84 @Children private final ValueNode[] children; |
85 | 85 |
86 public TestRootNode(ValueNode[] children) { | 86 public TestRootNode(ValueNode[] children) { |
87 super(null); | |
87 this.children = adoptChildren(children); | 88 this.children = adoptChildren(children); |
88 } | 89 } |
89 | 90 |
90 @Override | 91 @Override |
91 public Object execute(VirtualFrame frame) { | 92 public Object execute(VirtualFrame frame) { |
96 return sum; | 97 return sum; |
97 } | 98 } |
98 } | 99 } |
99 | 100 |
100 abstract class ValueNode extends Node { | 101 abstract class ValueNode extends Node { |
102 | |
103 public ValueNode() { | |
104 super(null); | |
105 } | |
101 | 106 |
102 abstract int execute(); | 107 abstract int execute(); |
103 } | 108 } |
104 | 109 |
105 class UnresolvedNode extends ValueNode { | 110 class UnresolvedNode extends ValueNode { |