GNU Info

Info Node: (gcc-300.info)Mixed Declarations

(gcc-300.info)Mixed Declarations


Next: Function Attributes Prev: Case Ranges Up: C Extensions
Enter node , (file) or (file)node

Mixed Declarations and Code
===========================

   ISO C99 and ISO C++ allow declarations and code to be freely mixed
within compound statements.  As an extension, GCC also allows this in
C89 mode.  For example, you could do:

     int i;
     ...
     i++;
     int j = i + 2;

   Each identifier is visible from where it is declared until the end of
the enclosing block.


automatically generated by info2www version 1.2.2.9