add non generator implement for 5.4 or older