Well, you might run out of memory if Index returns a bad status often enough ;)
J
Jonnyothan
@Jonnyothan
0
Reputation
2
Posts
21
Profile views
0
Followers
0
Following
Best posts made by Jonnyothan
This user hasn't posted anything yet.
Latest posts made by Jonnyothan
-
RE: WTF in class project spec
-
WTF in class project spec
I found this in the spec of my databases class project. The code has every sign of being poorly converted from C to C++, but this takes the cake. And yes, it's very common in this project for constructors to return a status code through a reference parameter. I guess they don't believe in exceptions.
Index * index = new Index(relation, status);
if(!index) return INSUFMEM;
if(status != OK) return status;