public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* in-class function definitions?
@ 2012-04-21 23:43 rick shelton
  2012-04-25 17:43 ` Dodji Seketeli
  0 siblings, 1 reply; 2+ messages in thread
From: rick shelton @ 2012-04-21 23:43 UTC (permalink / raw)
  To: gcc

How does the compiler handle an in-class function definition?
Example:

// File A.h

class A {
 int foo(void) { return x; }
 int bar(void);
 int x;

}

// File A.cc
#include "A.h"
int A::bar(void) { ... }

How is "foo()" represented in the AST when parsing A.cc?


Thanks,
rick

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-04-25 17:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-04-21 23:43 in-class function definitions? rick shelton
2012-04-25 17:43 ` Dodji Seketeli

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).