[fpc-pascal] Re: TObject and @TObject (are objects pointers?)

leledumbo leledumbo_cool at yahoo.co.id
Wed Sep 11 16:52:12 CEST 2013


> Shall I store  TTree in FItems or @TTree?

TTree

> If a variable obj is an TObject,  it is actually a pointer, which stores
> the address of the "real" object structure.

Correct

> If I add @obj into FItems, then I am storing the address of the obj
> variable

Correct

> However, if I add obj into FItems, I am storing the address of the object
> structure

Correct

> In the 2nd case, is there any "reference counter" for TObject which counts
> how many "pointers" are pointing to the structure?

AFAIK no






--
View this message in context: http://free-pascal-general.1045716.n5.nabble.com/TObject-and-TObject-are-objects-pointers-tp5716419p5716420.html
Sent from the Free Pascal - General mailing list archive at Nabble.com.



More information about the fpc-pascal mailing list