Changing beg and end to functions that return references to avoid compiler dependend behavior
Removing useless getter