Added support for if-then-else structures