File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
src/main/java/org/truffleruby Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ FinalizationService.Finalizer getFirstFinalizer() {
49
49
return finalizers .pollFirst ();
50
50
}
51
51
52
- void collectRoots (Collection <Object > roots ) {
52
+ public void collectRoots (Collection <Object > roots ) {
53
53
for (FinalizationService .Finalizer finalizer : finalizers ) {
54
54
final RubyDynamicObject root = finalizer .getRoot ();
55
55
if (root != null ) {
Original file line number Diff line number Diff line change 15
15
import org .truffleruby .language .RubyDynamicObject ;
16
16
import org .truffleruby .language .objects .ShapeCachingGuards ;
17
17
18
- import java .util .HashSet ;
18
+ import java .util .ArrayList ;
19
19
20
20
import com .oracle .truffle .api .CompilerDirectives .TruffleBoundary ;
21
21
import com .oracle .truffle .api .dsl .Cached ;
@@ -81,8 +81,8 @@ protected void writeBarrierUncached(RubyDynamicObject value) {
81
81
@ Specialization
82
82
@ TruffleBoundary
83
83
protected void writeBarrierFinalizer (FinalizerReference ref ) {
84
- HashSet <Object > roots = new HashSet <>();
85
- ref .getAdjacentObjects (roots );
84
+ ArrayList <Object > roots = new ArrayList <>();
85
+ ref .collectRoots (roots );
86
86
for (var root : roots ) {
87
87
SharedObjects .writeBarrier (getLanguage (), root );
88
88
}
You can’t perform that action at this time.
0 commit comments