Hacker News new | past | comments | ask | show | jobs | submit login

How does

    extern void foo(char a[..]);
differ from

    extern void foo(size_t dim, char a[dim]);
if they are meant to be binary compatible?



The programmer doesn't have to keep both in sync manually, so there is less chance that they blow up, as it happens regularly in C code, even after being reviewed.


I don’t recall that syntax being valid C. I thought the length modifier had to be a literal.


It doesn't matter, because it gets ignored anyway.




Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact

Search: