Can't return early from for-of loop

This fails:

function foo () {
  for ( let x of y ) {
    setTimeout( function () {
      console.log( x );
    });

    if ( x > 10 ) return;
  }
}