CompletableFuture<List<StackFrame>> (ThreadReference thread, int start, int length) { if (thread instanceof ThreadReferenceImpl && isAsyncEnabled()) { return reschedule(((ThreadReferenceImpl)thread).framesAsync(start, length)); } return toCompletableFuture(() -> thread.frames(start, length)); }