On Sun, 30 Jan 2011 00:16:20 +0100, Peter Alexander <[email protected]> wrote:

On 29/01/11 9:36 PM, Simen kjaeraas wrote:
Patrick Kreft <[email protected]> wrote:

On Sat, 29 Jan 2011 15:45:41 +0100, Tomek Sowiński <[email protected]> wrote:

Jim napisał:

I'm only discussing the heap/stack difference.

Classes with value semantics would be prone to the slicing problem.


That is because of the type system not classes or value semantic cause
of that.

Really? How would I go about stuffing a 16-byte class instance into the
8 bytes allocated on the stack, anyway?


I believe his point is that you can't, and the type system shouldn't allow it (as it does in C++).


Well not exactly, i mean it's true for D and all languages, which use nominal type system, but it's not true for all languages.
--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/

Reply via email to