Implement an indexed block function