Club Delphi  
    Paypal   FTP   CCD     Buscar   Trucos   Trabajo   Foros

Retroceder   Foros Club Delphi > Principal > OOP
Registrarse FAQ Miembros Calendario Guía de estilo Temas de Hoy

Coloboración Paypal con ClubDelphi

 
 
Herramientas Buscar en Tema Desplegado
  #6  
Antiguo 11-05-2005
Avatar de Ohcan
[Ohcan] Ohcan is offline
Miembro Premium
 
Registrado: ago 2004
Ubicación: Madrid (España)
Posts: 119
Poder: 22
Ohcan Va por buen camino
Question FreeAndNil

De la ayuda de Delphi:

Cita:
FreeAndNil procedure

Frees an object reference and replaces the reference with nil (Delphi) or NULL (C++).
Unit
SysUtils
Category
Pointer and address routines
Delphi syntax:
procedure FreeAndNil(var Obj);
C++ syntax:
extern PACKAGE void __fastcall FreeAndNil(void *Obj);
Description
Use FreeAndNil to ensure that a variable is nil (Delphi) or NULL (C++) after you free the object it references. Pass any variable that represents an object as the Obj parameter.
Warning: Obj must be an instance of a TObject descendant.
Entonces... ¿no sería mejor usar siempre ésto en vez del .free?
__________________
La violencia es el último recurso del incompetente. (Salvor Hardin)
Responder Con Cita
 



Normas de Publicación
no Puedes crear nuevos temas
no Puedes responder a temas
no Puedes adjuntar archivos
no Puedes editar tus mensajes

El código vB está habilitado
Las caritas están habilitado
Código [IMG] está habilitado
Código HTML está deshabilitado
Saltar a Foro


La franja horaria es GMT +2. Ahora son las 04:43:16.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
Traducción al castellano por el equipo de moderadores del Club Delphi
Copyright 1996-2007 Club Delphi