moved the pqueue into its own file, and simplified the store a bit
Merge pull request #12 from mikedewar/master

moved the pqueue into its own file, and simplified the store a bit