Compilers are not predictive to get the result exactly in the format humans want.
They obviously work on the limited syntax and semantics rule and as per some grammar (or rules you can say).
Errors are also Exceptions in Java that define exceptions which aren’t expected to be caught under normal circumstances.
So basically, an error is that problem which requires human handling for getting the correct result. Also, your assumption that errors aren’t handled is incorrect, as errors are reported like errors occurring during runtime. But, they don’t specifically correct the error and also they don’t provide much detail about the error.
solved Error Handling mechanism [closed]