[fpc-devel]SizeOf() reports 0 for Var Paramaters. (1.1)

2003-07-27 Thread Jon Sawyer
I'm not certain but I'm pretty sure that under 1.0.6 SizeOf() reported the proper size for Var paramaters. If not then I think a compiler warning may be in order for code like this... because I just spent an hour tracking down this problem. ;) Is there any other way of determining the

Re: [fpc-devel]SizeOf() reports 0 for Var Paramaters. (1.1)

2003-07-27 Thread Marco van de Voort
I'm not certain but I'm pretty sure that under 1.0.6 SizeOf() reported the proper size for Var paramaters. If not then I think a compiler warning may be in order for code like this... because I just spent an hour tracking down this problem. ;) Is there any other way of determining the

Re: [fpc-devel]SizeOf() reports 0 for Var Paramaters. (1.1)

2003-07-27 Thread Nikolay Nikolov
Marco van de Voort wrote: proceduer bla(var a: array of longint); // high() and sizeof() are possible and for procedure bla(var a); // none. I'm pretty certain it was the same for 1.0.6. This was already the case in BP/TP (e.g. see the blockwrite and blockread procedures that

Re: [fpc-devel]SizeOf() reports 0 for Var Paramaters. (1.1)

2003-07-27 Thread Marco van de Voort
Marco van de Voort wrote: proceduer bla(var a: array of longint); // high() and sizeof() are possible and for procedure bla(var a); // none. I'm pretty certain it was the same for 1.0.6. This was already the case in BP/TP (e.g. see the blockwrite and blockread

Re: [fpc-devel]SizeOf() reports 0 for Var Paramaters. (1.1)

2003-07-27 Thread Jon Sawyer
O_o Woah.. Weird. Ok.. I thought it worked.. but mabey not. 1.0.6 seems to return 4 for SizeOf() a var param. While 1.1 returns 0. Progam Test1; Procedure DoTest(var A); Begin Writeln('SizeOf A = ', SizeOf(A) ); end; var A : QWord; Begin A := 2390;

Re: [fpc-devel]SizeOf() reports 0 for Var Paramaters. (1.1)

2003-07-27 Thread Jon Sawyer
Fpc 1.0.6's SizeOf used to report 4 (regardless of the size of the 1.0.10 also report 4. 1.1 reports 0. parameter actually passed) and I submitted a bug report, so it was fixed: http://www.freepascal.org/bugs/showrec.php3?ID=2561 http://www.freepascal.org/bugs/showrec.php3?ID=2562 These