fixing syntax, some functions broken due to wrong version's syntax.  will fix in another commit

--HG--
extra : source : 6e2b9911617f3576d5dcc5c43a4908a99ce52b54
a number of small fixes

--HG--
extra : source : ae6723011d6adaf9580f7c7d6e38814e662dc6bd