Fixed bugs for #tdy, #tmr and #upc for ranged tasks