Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!news.albasani.net!newsfeed.freenet.ag!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!news.tele.dk!news.tele.dk!small.news.tele.dk!feed118.news.tele.dk!not-for-mail Newsgroups: comp.lang.c++ Subject: Re: delete[] p or delete[] *p References: <7ee927dd-06d3-4bf9-a25d-b6ed47bf1f78@z37g2000vbl.googlegroups.com> <549af0b7-ad06-4525-a820-be05a7dbe240@w7g2000yqe.googlegroups.com> <547d4b50-fa91-4990-9448-db647ac0d088@i39g2000prd.googlegroups.com> <77Gmp.7894$o81.6543@newsfe28.ams2> <2e231743-baf7-4412-b0b4-26fa2e093350@p16g2000vbi.googlegroups.com> <165e3c6f-18f4-4117-ba0c-d838eaef21e5@bl1g2000vbb.googlegroups.com> <_86np.2960$Ir.1849@newsfe13.ams2> From: Lasse Reichstein Nielsen Date: Fri, 08 Apr 2011 06:54:46 +0200 Message-ID: User-Agent: Gnus/5.1006 (Gnus v5.10.6) XEmacs/21.4 (Rational FORTRAN, windows-nt) Cancel-Lock: sha1:jTFTjo502KFAYrIkaPAY0TURI70= MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Lines: 26 Organization: TDC Totalloesninger NNTP-Posting-Host: 87.57.52.80 X-Trace: 1302238488 dtext01.news.tele.dk 36586 87.57.52.80:38956 X-Complaints-To: abuse@post.tele.dk Xref: x330-a1.tempe.blueboxinc.net comp.lang.c++:3304 "Paul" writes: > "Goran" wrote in message > news:e8b5f588-4dbb-4fc2-a593-de353c67538b@27g2000yqv.googlegroups.com... >> > Consider this: >> >> > int aa[2][2]; int* p=aa[0]; >> ... > With the above p points to an array , you think it only points to a > single int. You do not have any consideration for what is pointed to , > you incorrectly think the pointer type defines what is pointed to. Is it correct that in your opinion, in the above example, the pointer p points to all of 1) aa[0][0] , 2) aa[0] and 3) aa ? /L -- Lasse Reichstein Holst Nielsen DHTML Death Colors: 'Faith without judgement merely degrades the spirit divine.'