基础知识解惑
有如下类定义,请问类THouse的InstanceSize是__32___
TPoint = packed record
X: Longint;
Y: Longint;
end;
THouse = class
private
FOwner: string; //8
FPosition: TPoint; //8
FBounds: array[0..2] of Integer; //8
FLessees: TStrings; //4
public
procedure Paint; //4
property Owner: string read FOwner; //0
end;
A、24 B、28 C、32 D、40
寻求相关基础知识。
字符串string为什么是8而procedure方法是4?