Bjarne:The C++ exception-handling mechanism is designed to support handling of errors and other exceptional condition(hence the name)... This mechanism is designed to handle only synchronous exceptions, such as array range checks...
It looks like I'm not that far from the definition of the Master.
Well, I was rather refering to the fact that STL does not check indices as well... (unless you use vector::at).
I think what is the Master up to here is rather the fact that exceptions are not to be used to handle e.g. interrupts... OTOH, nice contraargument
Quote:
Quote:
Plus, you still have not explained how exceptions are going to help with multidimensional arrays...
I thought I did: How to you check nicely that j is a valid index in the v[i][j]? I personally think it is a pain to do if(i>=0&&i<v.GetCount()&& j>=0 && j<v[i].GetCount())