GNU C ANSI C һЩÇø±ð
1 ¿É±äÊý¾Ý½á¹¹
struct var_data
{
int len;
char data[0];
};
±éÀúlenºóÊý¾Ý
for(i = 0; i < s.len; i++)
{
printf("%02x",s.data[i]);
}
2 case ·¶Î§Çø¼ä ¡¾x£¬y¡¿
3 Óï¾ä±í´ï
#define min_t (type, x, y) \
({ type __x = (x); type __y = (y); __x < __y ? __x: __y;})
int ia, ib, mini;
float fa, fb, minf;
mini = min_t ( int, ia, ib);
minf = min_f (float, fa, fb);
±ê×¼c£º
#define min (x, y) ((x) < (y) ? (x) : (y))
´úÂëmin ( ++ia, ++ib£© ±»Õ¹¿ªÎª £¨£¨++ia) < (++ib) ? (++ia):(++ib)) ia£¬ib ±»¼ÓÁËÁ½´Î¡£
4 typeof
#define min(x, y) ( {\
const typeof(x) __x = £¨x£©; \
const typeof(y) __y = £¨y£©;\
(void) (&__x ==&__y); \
__x <_ _y ? __x : __y ;})
5 pr_debug ¿É·ÀÖ¹ÔÚ²ÎÊýÑ¡Ïî²»´ú±íÈκβÎÊýµÄʱºò ²»Êä³ö£¬¡£
6 ¿ÉÖ¸¶¨·¶Î§³õʼ»¯Êý×é unsigned char data [MAX] = { [0 ... MAX - 2] = 0};
½á¹¹Ìå³ÉÔ±³õʼ»¯½á¹¹Ì壺
struct file_operations ext2_file_operations =
{
llseek:generic_file_llseek,
read: generic_file_read,
}
ͬÑù£¬±ê×¼c£º
struct file_operations ext2_file_opreations =
{
.llseek = generic_file_llseek,
.read = generic_file_read,
}
.....
Ïà¹ØÎĵµ£º
/* find files from wildcards, for MicroSoft C v4.0 */
/* ------------------------------------------------------------ */
/* copyright 1986: */
/* Nourse Gregg & Browne, Inc. */
/* 1 Horizon Road. #612 ......
B/S½á¹¹£¨Browser/Server½á¹¹£©½á¹¹¼´ä¯ÀÀÆ÷ºÍ·þÎñÆ÷½á¹¹¡£ËüÊÇËæ×ÅInternet¼¼ÊõµÄÐËÆ𣬶ÔC/S½á¹¹µÄÒ»Öֱ仯»òÕ߸ĽøµÄ½á¹¹¡£ÔÚÕâÖֽṹÏ£¬Óû§¹¤×÷½çÃæÊÇͨ¹ýWWWä¯ÀÀÆ÷À´ÊµÏÖ£¬¼«ÉÙ²¿·ÖÊÂÎñÂß¼ÔÚÇ°¶Ë£¨Browser£©ÊµÏÖ£¬µ«ÊÇÖ÷ÒªÊÂÎñÂß¼ÔÚ·þÎñÆ÷¶Ë£¨Server£©ÊµÏÖ£¬ÐγÉËùνÈý²ã3-tier½á¹¹¡£ÕâÑù¾Í´ó´ó¼ò»¯ÁË¿Í»§¶ËµçÄÔÔØ ......
Ç×ÃܽӴ¥C¿É±ä²ÎÊýº¯Êý
±¾ÎÄ´Ó³ÌÐòԱʵ¼ùµÄ½Ç¶ÈÀ´ÆÊÎöC¿É±ä²ÎÊýº¯ÊýÔÚIntel 32λCPUÉϵÄʵÏÖÓëÔÀí
×÷ÕߣºÁÖº£·ã
ÍøÖ·:http://blog.csdn.net/linyt/archive/2008/04/02/2243605.aspx
[*]»¶ÓתÔØ£¬µ«ÇëÍêÕûתÔز¢×¢Ã÷×÷ÕßÒÔ¼°µØÖ·£¬ÇëÎðÓÃÓÚÈκÎÉÌÒµÓÃ;¡£
¿É±ä²ÎÊýº¯ÊýµÄʵÏÖ
Èç¹û˵CÓïÑÔ¾ ......
C1XÊÇCÓïÑÔ¼´C99±ê×¼Ö®ºó½«ÒªÍƳöµÄ×îбê×¼£¬Á˽⵽µÃÔÎÄÈçÏ£º
C1X is the unofficial name of the planned new standard for the C programming language. It is intended to replace the existing C standard. This predecessor is informally known as C99. The standard is not yet fin ......