It depends on what kind of mistake you’ve made. If you are doing something like calling_non_existent_function() you will get a fatal error. So you might want to play around with error_reporting. Using an IDE would be sufficient to avoid stuff like that.
When you are doing something like $user->calling_non_existent_function(), blahblah::blahblah(), echo $user->non-existend-paramter etc Yii will be able to handle it for you with CException and given you are in the debug mode, you will get a nice stack of what went wrong.
Also since Yii uses __set extensively, by design you won’t be able to do something like $user->non_declared_variable = “foo”, which you would normally be able to do. (with E_NOTICE you would get warned, though)