More efficient inline for index