开发者

How to calculate the amount of memory occupied by the variable in Pascal?

开发者 https://www.devze.com 2023-03-17 08:20 出处:网络
I need to calculate the amount of memory that any variable takes. Thanx for any input. EDITED: I didn\'t notice that I need to开发者_Python百科 calculate it manually (by hand). ThanxSizeOf(variable)

I need to calculate the amount of memory that any variable takes. Thanx for any input.

EDITED: I didn't notice that I need to开发者_Python百科 calculate it manually (by hand). Thanx


SizeOf(variable)

of course that only goes for the variable not to any additional memory the variable might point to, or any alignment if it is part of a structured type.

0

精彩评论

暂无评论...
验证码 换一张
取 消