Closed
Description
Assuming the following code:
function doSomething() {
alert("Did something");
}
doSomething;
Would it be possible for TypeScript to complain about the doSomething;
line, notifying the user that the statement is a no-op and maybe even suggesting adding parentheses to call the function? Or do you folks consider that kind of problems to definitely be a linter error, rather than something the compiler should look out for?
I searched the bugtracker but couldn't find any similar requests, my apologies if I missed them. I don't even know how feasible this would be, maybe ECMAScript has intricacies that make it impossible in all but the simplest cases, but I thought it couldn't hurt to suggest it.