[fpc-devel] Redefine FillChar() to use out parameter instead

Marc Weustink marc.weustink at cuperus.nl
Thu Nov 19 10:53:45 CET 2009


Graeme Geldenhuys wrote:
> Florian Klaempfl wrote:
>> initialized. But be warned: with such a parameter type you can easily
>> create memory leaks with automated types like ansistrings.
> 
> 
> Well, isn't that what heaptrc is for?  

No, the language should protect you from such easy to make mistakes.
In theory don't want to know how a type is implemented and if it is safe 
to pass as parameter (unless the compiler forbids using varout for such 
types)
Weren't you recently involved in a discussion about knowing the 
under-the-hood implementation of automated types and their behaviour ?


Marc



More information about the fpc-devel mailing list