Click here to Skip to main content
15,868,016 members
Articles / Programming Languages / C++

Checking an C-Array Size at Compile Time

Rate me:
Please Sign up or sign in to vote.
4.56/5 (6 votes)
7 Jul 2011CPOL2 min read 17.3K   2  
Be sure that your array has the right size - without using size_of!
In this tip, you will learn how to check a C-array size at compile time

Alternatives

Members may post updates or alternatives to this current article in order to show different approaches or add new features.

No alternatives have been posted.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer
Germany Germany
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions