What is C GNU-isms?

I recently migrated a project from GCC to clang (in which I fixed the GNU-isms C series). This made me wonder: what are the GNU-isms C (extensions for the C language supported in GCC that are not standardized)? Is there an exhaustive list anywhere?

+3
source share
3 answers

Here is a fairly complete list directly from the GCC website. There seems to be quite a lot, so I wish you the best of luck to sift it!

http://gcc.gnu.org/onlinedocs/gcc-4.2.0/gcc/C-Extensions.html

+8
source

, Beta , , . GNU, .

, , GCC C99, ( Microsoft V++). , C99 .

0

GNUisms, , - .

 struct canmsg_t {
      short     flags;
      int       cob;
      canmsg_id_t   id;
      unsigned long timestamp;
      unsigned int  length;
      unsigned char data[CAN_MSG_LENGTH];
 };

 canmsg_t msg = 
 {
      ["flags"] = 0x00;
      ["cob"]   = 0;
      ["id"]    = 0x534;
      ["timestamp"] = 0;
      ["length"] = 1;
      ["data"] = { 0 };
 }

, , , 100 + .

0

Source: https://habr.com/ru/post/1730654/


All Articles