Fix issue 10551 CTFE array pointer passed by ref

IndexExp needs to consider the case where we need a reference