Made it work in scala 2.10

May not build in current configuration; will fix the configuration later.