Re: How do i depend on struct composition

2013-08-22 Thread JS
On Thursday, 22 August 2013 at 23:10:40 UTC, anonymous wrote: On Thursday, 22 August 2013 at 22:32:53 UTC, JS wrote: On Thursday, 22 August 2013 at 21:07:27 UTC, Mariusz `shd` Gliwiński wrote: [...] struct InnerC { void operate() { auto ptr = this-(void*).sizeof; /* do something with point

Re: How do i depend on struct composition

2013-08-22 Thread anonymous
On Thursday, 22 August 2013 at 22:32:53 UTC, JS wrote: On Thursday, 22 August 2013 at 21:07:27 UTC, Mariusz `shd` Gliwiński wrote: [...] struct InnerC { void operate() { auto ptr = this-(void*).sizeof; /* do something with pointer */ } } struct Compound(Inner) { Inner a_or_b; Inner

Re: How do i depend on struct composition

2013-08-22 Thread JS
On Thursday, 22 August 2013 at 21:07:27 UTC, Mariusz `shd` Gliwiński wrote: Let me try to illustrate my question by following pseudo-code: struct InnerA { /* .. */ void* ptr; } struct InnerB { /* .. */ void* ptr; } struct InnerC { void operate() { auto ptr = this-(void*).sizeof;

How do i depend on struct composition

2013-08-22 Thread Mariusz `shd` Gliwiński
Let me try to illustrate my question by following pseudo-code: struct InnerA { /* .. */ void* ptr; } struct InnerB { /* .. */ void* ptr; } struct InnerC { void operate() { auto ptr = this-(void*).sizeof; /* do something with pointer */ } } struct Compound(Inner) { Inner