generic constructor for all ftree data structures; fix pq bugs

- use generics to implement generic constructor for all ftree data structures
  - so all can use ft-cons, etc functions without duplicating code

- pqueue changes:
  - remove inf parameter
  - dont store cmp parameter
  - fix bug in top+rest

- update tests