I always read/hear people say "I use set_error_handler function to throw an excpetion whenever an error occurs so I'm only left with using exceptions as the error handling mechanism and don't bother using two mechanims to handle errors (i.e. php native errors and exceptions)" .
In my understantig this is not properly stated , php native error mechanism is primarly intended as an error-reporting mechanism and not as an error handling one,is this right ?
Php standard functions whenever triggering errors on failures should (and I think do) also use an error code based strategy , to let the programmer take appropriate actions, once again is this correct ?
As error-code based strategy I mean they could directly return error codes or give the programmer the chance to know about the problem by calling an appropriate functions or use others strategy like these.
So , shouldn't we say more properly that we use set_error_handler and php native error reporting mechanism as a trick to be only left working with exceptions and so we don't bother check for errors values?
PS: I'm fairly new to PHP , don't be too rude if I'm saying something totally crazy :)