Fixed memory leak in DATR/ELF handling of dynamic compilation
fixed argument order bug in previous patch
Merge remote-tracking branch 'roger/master' into HEAD
Revert "Fix clause leak on each iteration"

This reverts commit c41408f0b3724e57e978f75330c7a7981d937262.
Obviated by Roger's fixes in 90b8d29 and 9dad9fd