Delete or delete ?
Posted on 2003-02-26
I just don't understand??
ptrInt = new int;
for(int i=0;i<1000;i++) ptrInt[i] = i;
int * ptrInt;
This is an example of a class that I create & delete many times to test the memory... Funny thing is both (delete and delete) clear all the memory!!! I was expecting a lack of memory by using 'delete' on a array pointer!
Is someone can explain me that?
By the way, I'm using the LINUX /proc/[# of my proc]/status to look at the memory. There's many information like RSS, Size, Data, ... I can't find any description of those information. I use RSS to watch the memory. Can you tell me what mean all those information... like Data.