2011/9/7 Leonardo M. Ramé <martinr...@yahoo.com>:
> From: Yann Bat <batyann...@gmail.com>
>
>
> The error message is correct, because inside the scope of method  Bug, _T 
> points to nil, and the size of nil is 0, so 10000 div 0 raises the error.
>

I think that SizeOf(_T) should be unknown rather than 0. The compiler
should not make any assumption about _T before specialization.

> What about using Result := 1000000 div SizeOf(FField); ?

Same error with SizeOf(FField).



>
> Leonardo.
> _______________________________________________
> fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
>
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to