URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Go to most recent revision |
Only display areas with differences |
Details |
Blame |
View Log
Rev 154 |
Rev 816 |
// { dg-do run }
|
// { dg-do run }
|
// Example of static member constants
|
// Example of static member constants
|
|
|
extern "C" int printf (const char *, ...);
|
extern "C" int printf (const char *, ...);
|
|
|
struct T {
|
struct T {
|
static const char letter = 'a'; // this is the new stuff!
|
static const char letter = 'a'; // this is the new stuff!
|
char x[letter];
|
char x[letter];
|
void f();
|
void f();
|
};
|
};
|
|
|
void T::f() { printf ("%p", &letter); }
|
void T::f() { printf ("%p", &letter); }
|
const char T::letter; // still need def after class
|
const char T::letter; // still need def after class
|
|
|
int main() { }
|
int main() { }
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.