fixed out of memory error and added tests for let in semantic analyzer