From: michael DOT mauch AT gmx DOT de (Michael Mauch) Newsgroups: comp.os.msdos.djgpp Subject: Re: Memory leak. Date: Mon, 06 Oct 1997 19:26:00 +0200 Organization: Gerhard-Mercator-Universitaet -GH- Duisburg Lines: 26 Message-ID: <3439043e.32895652@news.uni-duisburg.de> References: <3 DOT 0 DOT 16 DOT 19971003101449 DOT 36e7aec2 AT hem1 DOT passagen DOT se> <613s4d$hrm AT dfw-ixnews3 DOT ix DOT netcom DOT com> <3435E44A DOT 5C65B10B AT alcyone DOT com> <3436785d DOT 8243393 AT news DOT uni-duisburg DOT de> <616g9n$i7 AT dfw-ixnews11 DOT ix DOT netcom DOT com> NNTP-Posting-Host: ppp89.uni-duisburg.de Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk On 4 Oct 1997 22:34:31 GMT, firewind wrote: > Michael Mauch wrote: > > sizeof is an (unary) operator, not a function, so > > > x = sizeof int; > > > is just as valid as > > > x = +4; > > Certainly not! Erik was correct; my lack of parenthesis around 'int' -was- > a typo. Did you test code that does something like "x = sizeof int"? I > garuntee that gcc will report: > > whatever.c:x: parse error before `int' > > Parenthesis are NOT required around a -variable- when the sizeof operator is > applied, but they ARE required when it is being applied to a type name. Yes, you're right. I didn't test it and `sizeof int´ really doesn't work, whereas `char c; x = sizeof c;´ does. I'm sorry. Regards... Michael