Made apply_op be const.
Made sindex_val be named.