Change this to the following:

     |   arraye=expression LSQUARE indexe=expression RSQUARE  { $ret = factory.arrayElemRef(Arrays.<Expression>toList(arraye,indexe);}