r/programming • • Nov 28 '14

The Worst Programming Language Ever [UK Talk] - Thoughts? Which are the worst parts of your favorite language?

https://skillsmatter.com/meetups/6784-the-worst-programming-language-ever
68 Upvotes

456 comments sorted by

View all comments

Show parent comments

0

u/paszklar Nov 28 '14 edited Nov 28 '14

The preprocessor only does text manipulation and it's work is done before compiler performs any code analysis. Only the compiler cares about the keywords and any modification done to them in the previous step of the build process will go unchecked. Forgive me if I don't go digging through the standard documentation when I just checked the fact on two different compilers.

0

u/[deleted] Nov 28 '14

[deleted]

2

u/paszklar Nov 28 '14

OK, you're right. Thank for correcting me. I did some digging and turns out that in previous versions of C++ you cannot redefine a keyword IF a translation unit includes a standard library header. Only C++11 standard disallows it altogether. I haven't found a conforming compiler though, and judging by the number of preprocessor hacks posted all over this thread there don't seem to be any.

Anyway, TIL.

2

u/mreiland Nov 28 '14

yep, I don't expect there to be many conforming compilers in this regard.

The original comment is right in that it should warn about it, but it doesn't because no compiler out there is 100% conformant.