Adds ARC support, fixes bug with peek to prevent an exception being raised if index is out of range, adds further comments