val cycleRunnable = Runnable {
handler.postDelayed(cycleRunnable,100)
}
I am getting error Error:(219, 29) Type checking has run into a recursive problem. Easiest workaround: specify types of your declarations explicitly
But its exact java version doesn't have any error
private final Runnable cycleRunnable = new Runnable() {
public void run() {
handler.postDelayed(cycleRunnable, POST_DELAY);
}
};