您的位置:首页 > 运维架构 > Linux

安装red hat linux enterprise 4 的步骤

2008-04-08 14:58 666 查看
Code demostrating "Distinguishing C++ Declarations from Expressions" in The Definitive ANTLR Reference.

 

#include <stdio.h>

typedef int I;
char x = 'a';
void foo() {
I(x);
x = 10;
printf("x = %d in foo\n", x);
}

struct _node {
int m;
};

typedef struct _node * T;

T(*a)(int);
int main(int argc, const char *argv[])
{
printf("cast %d, %d\n", I(x), (I)x);
foo();
printf("x = %d in main\n", x);

struct _node n;
T one = &n;
T *a = &one;

T(*a)->m = 8;
printf("m: %d\n", (*a)->m);
return 0;
}

 
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: