[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to test memory allocation with new ?
From: |
Sharad Kala |
Subject: |
Re: How to test memory allocation with new ? |
Date: |
Tue, 2 Nov 2004 14:21:03 +0530 |
"Method Man" <a@b.c> wrote in message
> Do you mean both statements are problematic? Shouldn't 'pp[0] = 0' be OK
> since it is equivalent to *pp = 0 (assigning the allocated char the null
> value)?
No, only pp[1] is problematic. This gets evaluated to *(pp + 1), pp [0] as
you point out is same as *pp.
Sharad
Re: How to test memory allocation with new ?, Cosmin Calinescu, 2004/11/01
Re: How to test memory allocation with new ?, Larry I Smith, 2004/11/01