Use erase instead of substr

- Also, tokens store a pointer to the filename as opposed to copying the
string.
Replace my spaces with tabs
Merge pull request #12 from kanielc/use-erase

Use erase instead of substr