Fixed dead code removal not working properly, improved expression parsing to determine dead IF branches.