add some utility funcs
Merge brat pushnch 'master' of https://github.com/mattydoincode/PLT