fixes #1009
made some tests green
ENDB: got rid of deprecated 'nil' stmt
fixes a typo
Merge branch 'devel' of https://github.com/Araq/Nimrod into devel