Added fix from Ciprian Khlud<ciprian.mustiata@yahoo.com>: Fix in
hoping to address the issues regarding some edge cases of remove
redundant variables in relation with functions.