digitalmars.D - Two C99 features
- bearophile (10/10) Nov 27 2008 In C99 there are two features that may be useful in D programs too:
In C99 there are two features that may be useful in D programs too: 1) The restrict keyword: http://en.wikipedia.org/wiki/Restrict http://www.cellperformance.com/mike_acton/2006/05/demystifying_the_restrict_keyw.html 2) And the stack allocated variable-length arrays (that reduce most of the need for alloca() and can be used for small arrays): http://en.wikipedia.org/wiki/Variable-length_array This is less necessary in D because it has built-in dynamic arrays, but for small arrays it can be useful, as a performance optimization feature. Are there proposals of adding them to D? Bye, bearophile
Nov 27 2008