← Back to team overview

zorba-coders team mailing list archive

Re: [Merge] lp:~zorba-coders/zorba/feature-mem_size into lp:zorba

 

Please note the distinction between alloc_sizeof() and mem_sizeof().  The former obtains the *additionally* dynamically allocated memory for an object of type T.  An 'int' has no additional memory beyond the size of the 'int' itself, so the result of 0 is correct.

Why do you want to expose *only* alloc_size()?  It's kind of awkward without mem_sizeof().

BTW: alloc_size() isn't really meant to be called explicitly.  You *can* do it and it will give you the correct answer, but it's not the answer you really want.  Again, note the distinction between alloc_sizeof() and mem_sizeof().
-- 
https://code.launchpad.net/~zorba-coders/zorba/feature-mem_size/+merge/114764
Your team Zorba Coders is subscribed to branch lp:zorba.


References