This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: GIMPLE Question
- From: Dave Korn <dave dot korn dot cygwin at gmail dot com>
- To: Kyle Girard <kyle at kdmanalytics dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: Fri, 25 Feb 2011 16:22:58 +0000
- Subject: Re: GIMPLE Question
- References: <1298647212.8393.37.camel@Tak>
On 25/02/2011 15:20, Kyle Girard wrote:
> foo.hh
> ======
>
> class A
> {
> };
>
> class foo
> {
> A a;
> public:
> void bar(A & aa);
> };
>
>
> foo.cc
> ======
>
> #include "foo.hh"
>
> void foo::bar(A & aa)
> {
> a = aa;
> }
>
>
> However the gimple generated via g++-4.5 -c -fdump-tree-gimple foo.cc
>
> is this:
>
> void foo::bar(A&) (struct foo * const this, struct A & aa)
> {
> GIMPLE_NOP
> }
>
>
> My question is this, what do I have to do to get the contents of the bar
> method?
That *is* the content of the bar method. What exactly do you expect to see
happening when you assign a class with no members? There's nothing to do!
cheers,
DaveK