5.70 Mixed declarations and statements in C99

C99 enables you to mix declarations and statements within compound statements, like in C++.

For example:

void foo(float i)
    i = (i > 0) ? -i : i;
    float j = sqrt(i);    // illegal in C90
Non-ConfidentialPDF file icon PDF versionARM DUI0472M
Copyright © 2010-2016 ARM Limited or its affiliates. All rights reserved.