const in array bound expression

Karl Heuer karl at haddock.ISC.COM
Thu Aug 4 11:54:28 AEST 1988


In article <123 at peritus.UUCP> preston at peritus.UUCP (Preston Gardner) writes:
>What constitutes a constant expression under the new ANSI standard?  The
>following should be legal:
>    const int i = 5;
>    int a[i];

It isn't, though.  I believe this is what Bjarne meant when he said that when
X3J11 took |const| from C++, they "watered it down".

Karl W. Z. Heuer (ima!haddock!karl or karl at haddock.isc.com), The Walking Lint



More information about the Comp.lang.c mailing list